protected function preText() {
$this->getOutput()->addModules( 'mediawiki.special.pageLanguage' );
+ return parent::preText();
}
protected function getFormFields() {
$this->getContext(),
$title,
$newLanguage,
- $data['reason'] === null ? '' : $data['reason']
+ $data['reason'] ?? ''
);
}
}
// Hardcoded [def] if the language is set to null
- $logOld = $oldLanguage ? $oldLanguage : $defLang . '[def]';
- $logNew = $newLanguage ? $newLanguage : $defLang . '[def]';
+ $logOld = $oldLanguage ?: $defLang . '[def]';
+ $logNew = $newLanguage ?: $defLang . '[def]';
// Writing new page language to database
$dbw->update(