mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-09-24 02:38:40 +00:00
Fix notice caused by not passing the WebRequest object by reference
It makes no sense that we should have to pass this by reference but if we don't do it, we get a PHP notice. Bug: 52466 Change-Id: Ibc8e33c4776a325cd32b6526dacc200994a73f7f
This commit is contained in:
parent
19a705de87
commit
1c4c86e7e3
|
@ -252,7 +252,8 @@ class ApiVisualEditor extends ApiBase {
|
|||
// HACK: Build a fake EditPage so we can get checkboxes from it
|
||||
$article = new Article( $page ); // Deliberately omitting ,0 so oldid comes from request
|
||||
$ep = new EditPage( $article );
|
||||
$ep->importFormData( $this->getRequest() );
|
||||
$req = $this->getRequest();
|
||||
$ep->importFormData( $req ); // By reference for some reason (bug 52466)
|
||||
$tabindex = 0;
|
||||
$states = array( 'minor' => false, 'watch' => false );
|
||||
$checkboxes = $ep->getCheckboxes( $tabindex, $states );
|
||||
|
|
Loading…
Reference in a new issue