Merge "Follow-up Ifdc951f: Don't use getLocalApi when VE not available"

This commit is contained in:
jenkins-bot 2018-06-10 22:39:29 +00:00 committed by Gerrit Code Review
commit 4e17f2f131

View file

@ -41,7 +41,7 @@ mw.libs.ve.SwitchPopupWidget = function MWLibsVESwitchPopupWidget( mode, config
showAgainCheckbox = new OO.ui.CheckboxInputWidget()
.on( 'change', function ( value ) {
var configValue = value ? '1' : '';
ve.init.target.getLocalApi().saveOption( option, configValue );
new mw.Api().saveOption( option, configValue );
mw.user.options.set( option, configValue );
} );