Merge "VisualEditorDataModule: Pass save/publish button label to 'missingsummary' message"

This commit is contained in:
jenkins-bot 2017-05-30 01:32:28 +00:00 committed by Gerrit Code Review
commit eb6cf0d79a

View file

@ -44,10 +44,14 @@ class VisualEditorDataModule extends ResourceLoaderModule {
}
protected function getMessageInfo( ResourceLoaderContext $context ) {
global $wgEditSubmitButtonLabelPublish;
$saveButtonLabelKey = $wgEditSubmitButtonLabelPublish ? 'publishpage' : 'savearticle';
$saveButtonLabel = $context->msg( $saveButtonLabelKey )->text();
// Messages to be exported as parsed html
$parseMsgs = [
'minoredit' => $context->msg( 'minoredit' ),
'missingsummary' => $context->msg( 'missingsummary' ),
'missingsummary' => $context->msg( 'missingsummary', $saveButtonLabel ),
'summary' => $context->msg( 'summary' ),
'watchthis' => $context->msg( 'watchthis' ),
'visualeditor-browserwarning' => $context->msg( 'visualeditor-browserwarning' ),