mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-11-15 10:35:48 +00:00
Merge "Add debugging help to VisualEditor"
This commit is contained in:
commit
8951b983a8
|
@ -83,7 +83,7 @@ class ApiVisualEditor extends ApiBase {
|
||||||
} else {
|
} else {
|
||||||
$message = 'MWHttpRequest error';
|
$message = 'MWHttpRequest error';
|
||||||
}
|
}
|
||||||
$this->dieUsage( $message, 'parsoidserver-' . $code );
|
$this->dieUsage( "$message: " . $req->getContent(), 'parsoidserver-' . $code );
|
||||||
}
|
}
|
||||||
// TODO pass through X-Parsoid-Performance header, merge with getHTML above
|
// TODO pass through X-Parsoid-Performance header, merge with getHTML above
|
||||||
return $req->getContent();
|
return $req->getContent();
|
||||||
|
@ -306,6 +306,7 @@ class ApiVisualEditor extends ApiBase {
|
||||||
$html = gzinflate( base64_decode( substr( $html, 11 ) ) );
|
$html = gzinflate( base64_decode( substr( $html, 11 ) ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
wfDebugLog( 'visualeditor', "called on '$page' with paction: '{$params['paction']}'" );
|
||||||
switch ( $params['paction'] ) {
|
switch ( $params['paction'] ) {
|
||||||
case 'parse':
|
case 'parse':
|
||||||
$parsed = $this->getHTML( $page, $parserParams );
|
$parsed = $this->getHTML( $page, $parserParams );
|
||||||
|
|
Loading…
Reference in a new issue