Merge "ApiVisualEditorEditor#postData: Use isset on oldid post param"

This commit is contained in:
jenkins-bot 2017-01-04 22:30:41 +00:00 committed by Gerrit Code Review
commit 679addb9d6

View file

@ -183,11 +183,8 @@ class ApiVisualEditorEdit extends ApiVisualEditor {
}
protected function postData( $path, $title, $data, $parserParams, $etag ) {
if ( $parserParams['oldid'] === 0 ) {
$parserParams['oldid'] = '';
}
$path .= urlencode( $title->getPrefixedDBkey() );
if ( $parserParams['oldid'] ) {
if ( isset( $parserParams['oldid'] ) && $parserParams['oldid'] ) {
$path .= '/' . $parserParams['oldid'];
}
return $this->requestRestbase(