ApiVisualEditorEdit: Use 'html' format for API errors so we can see them

The Translate extension emits errors when the saved text is in error —

* pt-parse-open,
* pt-parse-close,
* pt-shake-position,
* pt-shake-multiple,
* pt-shake-empty, or
* pt-parse-nested

Switching to 'html' error message format means we pay attention to the top
error, displayed in the user's language. This avoids showing 'editaborted'
generic messages when we can actually help people with specifics.

Change-Id: Id9d7e510e32a3a13cc061648679e01edd68a3868
This commit is contained in:
James D. Forrester 2017-01-11 16:30:01 -08:00
parent 002b0adef0
commit 446b16e71a

View file

@ -25,6 +25,7 @@ class ApiVisualEditorEdit extends ApiVisualEditor {
'basetimestamp' => $params['basetimestamp'],
'starttimestamp' => $params['starttimestamp'],
'token' => $params['token'],
'errorformat' => 'html',
];
if ( $params['minor'] ) {