Edit check: Turn on when ecenable=1 is set

Bug: T345297
Change-Id: Ie41258dbf87ef9ae00cdf830bf8cb84ed848d0a7
(cherry picked from commit 7c403b2c98)
This commit is contained in:
Ed Sanders 2023-09-05 14:34:20 +01:00 committed by DLynch
parent e9479250ee
commit 901e70ac9d
2 changed files with 3 additions and 2 deletions

View file

@ -137,7 +137,7 @@ if ( mw.config.get( 'wgVisualEditorConfig' ).editCheckTagging ) {
} );
}
if ( mw.config.get( 'wgVisualEditorConfig' ).editCheck ) {
if ( mw.config.get( 'wgVisualEditorConfig' ).editCheck || new URL( location.href ).searchParams.get( 'ecenable' ) ) {
mw.hook( 've.preSaveProcess' ).add( function ( saveProcess, target ) {
var surface = target.getSurface();

View file

@ -37,7 +37,8 @@
modules.push( 'ext.visualEditor.mwwikitext' );
}
if ( conf.editCheckTagging || conf.editCheck ) {
var editCheck = conf.editCheck || !!url.searchParams.get( 'ecenable' );
if ( conf.editCheckTagging || editCheck ) {
modules.push( 'ext.visualEditor.editCheck' );
}