Merge "Allow 'wikitext' to be an empty string in save API"

This commit is contained in:
jenkins-bot 2016-11-21 18:25:29 +00:00 committed by Gerrit Code Review
commit 42bc9f39bd

View file

@ -261,8 +261,9 @@ class ApiVisualEditorEdit extends ApiVisualEditor {
$parserParams['oldid'] = $params['oldid'];
}
$wikitext = $params['wikitext'];
if ( !$wikitext ) {
if ( isset( $params['wikitext'] ) ) {
$wikitext = $params['wikitext'];
} else {
$wikitext = $this->getWikitext( $title, $params, $parserParams );
}