diff --git a/modules/ve-mw/init/targets/ve.init.mw.DesktopArticleTarget.js b/modules/ve-mw/init/targets/ve.init.mw.DesktopArticleTarget.js index ba309c8b2c..bb18d181ae 100644 --- a/modules/ve-mw/init/targets/ve.init.mw.DesktopArticleTarget.js +++ b/modules/ve-mw/init/targets/ve.init.mw.DesktopArticleTarget.js @@ -1673,12 +1673,24 @@ ve.init.mw.DesktopArticleTarget.prototype.resetDocumentOpacity = function () { this.getSurface().getView().getDocument().getDocumentNode().$element.css( 'opacity', 1 ); }; +/** + * Set temporary redirect interface to match the current state of redirection in the editor. + * + * @param {string|null} title Current redirect target, or null if none + */ +ve.init.mw.DesktopArticleTarget.prototype.setFakeRedirectInterface = function ( title ) { + this.updateRedirectInterface( + title ? this.constructor.static.buildRedirectSub() : $(), + title ? this.constructor.static.buildRedirectMsg( title ) : $() + ); +}; + /** * Set the redirect interface to match the page's redirect state. */ ve.init.mw.DesktopArticleTarget.prototype.setRealRedirectInterface = function () { this.updateRedirectInterface( - mw.config.get( 'wgIsRedirect' ) ? this.buildRedirectSub() : $(), + mw.config.get( 'wgIsRedirect' ) ? this.constructor.static.buildRedirectSub() : $(), // Remove our custom content header - the original one in #mw-content-text will be shown $() ); diff --git a/modules/ve-mw/init/ve.init.mw.ArticleTarget.js b/modules/ve-mw/init/ve.init.mw.ArticleTarget.js index 527929733f..33d9ac1beb 100644 --- a/modules/ve-mw/init/ve.init.mw.ArticleTarget.js +++ b/modules/ve-mw/init/ve.init.mw.ArticleTarget.js @@ -2581,26 +2581,3 @@ ve.init.mw.ArticleTarget.prototype.updateRedirectInterface = function ( $sub, $m $( '#mw-content-text' ).before( $msg ); } }; - -/** - * Set temporary redirect interface to match the current state of redirection in the editor. - * - * @param {string|null} title Current redirect target, or null if none - */ -ve.init.mw.ArticleTarget.prototype.setFakeRedirectInterface = function ( title ) { - this.updateRedirectInterface( - title ? this.constructor.static.buildRedirectSub() : $(), - title ? this.constructor.static.buildRedirectMsg( title ) : $() - ); -}; - -/** - * Set the redirect interface to match the page's redirect state. - */ -ve.init.mw.ArticleTarget.prototype.setRealRedirectInterface = function () { - this.updateRedirectInterface( - mw.config.get( 'wgIsRedirect' ) ? this.buildRedirectSub() : $(), - // Remove our custom content header - the original one in #mw-content-text will be shown - $() - ); -};