Merge "VisualEditorDataModule: Use ResourceLoaderContext::encodeJson"

This commit is contained in:
jenkins-bot 2021-02-19 04:09:51 +00:00 committed by Gerrit Code Review
commit d30aaa07a0

View file

@ -32,13 +32,11 @@ class VisualEditorDataModule extends ResourceLoaderModule {
$plainMessages[ $msgKey ] = $msgObj->plain(); $plainMessages[ $msgKey ] = $msgObj->plain();
} }
return 've.init.platform.addParsedMessages(' . FormatJson::encode( return 've.init.platform.addParsedMessages(' . $context->encodeJson(
$parsedMessages, $parsedMessages
(bool)ResourceLoader::inDebugMode()
) . ');' . ) . ');' .
've.init.platform.addMessages(' . FormatJson::encode( 've.init.platform.addMessages(' . $context->encodeJson(
$plainMessages, $plainMessages
(bool)ResourceLoader::inDebugMode()
) . ');'; ) . ');';
} }