mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-11-29 08:34:54 +00:00
Merge "Check useeditwarning preference before showing warning when browsing away from editor"
This commit is contained in:
commit
987b10da94
|
@ -1569,7 +1569,7 @@ ve.init.mw.ViewPageTarget.prototype.onBeforeUnload = function () {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
// Check if there's been an edit
|
// Check if there's been an edit
|
||||||
if ( this.surface && this.edited ) {
|
if ( this.surface && this.edited && mw.user.options.get( 'useeditwarning' ) ) {
|
||||||
// Return our message
|
// Return our message
|
||||||
message = ve.msg( 'visualeditor-viewpage-savewarning' );
|
message = ve.msg( 'visualeditor-viewpage-savewarning' );
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue