SpecialGadgets: Avoid setting internal fields of HTMLForm

HTMLForm would handle title itself, don't need to set it manually here.

Depends-On: Iaec81a2fb49162f2fc764f143f88e887572a3a0b
Change-Id: I4a9788e853463e51570ba7c04a8bd40f1ed95cfa
This commit is contained in:
Func 2022-03-20 22:07:38 +08:00
parent f9d09841cf
commit 3c23c202e5
2 changed files with 2 additions and 2 deletions

View file

@ -8,7 +8,7 @@
"descriptionmsg": "gadgets-desc",
"license-name": "GPL-2.0-or-later",
"requires": {
"MediaWiki": ">= 1.38.0"
"MediaWiki": ">= 1.39.0"
},
"type": "other",
"namespaces": [

View file

@ -306,7 +306,7 @@ class SpecialGadgets extends SpecialPage {
$htmlForm = HTMLForm::factory( 'ooui', [], $this->getContext() );
$htmlForm
->addHiddenField( 'title', SpecialPage::getTitleFor( 'Export' )->getPrefixedDBKey() )
->setTitle( SpecialPage::getTitleFor( 'Export' ) )
->addHiddenField( 'pages', $exportList )
->addHiddenField( 'wpDownload', '1' )
->addHiddenField( 'templates', '1' )