mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-11-24 06:24:08 +00:00
ve.init.mw.ArticleTarget: Skip prompt when switching to VE from NWE section editing if unchanged
Bug: T136267 Change-Id: I30eae20baca2e16fa5f710485eab213edd5c4a08
This commit is contained in:
parent
33b59909df
commit
a387778ac3
|
@ -2466,6 +2466,12 @@ ve.init.mw.ArticleTarget.prototype.switchToVisualEditor = function () {
|
|||
var dataPromise, windowManager, switchWindow,
|
||||
target = this;
|
||||
|
||||
if ( !this.edited ) {
|
||||
this.section = null;
|
||||
this.reloadSurface( 'visual' );
|
||||
return;
|
||||
}
|
||||
|
||||
// Show a discard-only confirm dialog, and then reload the whole page, if:
|
||||
if (
|
||||
// * section editing in WT, as WT -> VE is not yet supported, or
|
||||
|
|
Loading…
Reference in a new issue