Use explicit nullable type on parameter arguments (for PHP 8.4)

Implicitly marking parameter $... as nullable is deprecated in PHP
8.4. The explicit nullable type must be used instead.

Bug: T376276
Change-Id: I867b777f6799a383f1a19165fbaa7b4c0d47d76c
This commit is contained in:
Andre Klapper 2024-10-26 15:08:21 +02:00
parent f8bce0e016
commit ee4d9dd5d5
3 changed files with 3 additions and 3 deletions

View file

@ -42,7 +42,7 @@ class OATHAuthServices {
* @param MediaWikiServices|null $services
* @return OATHAuthServices
*/
public static function getInstance( MediaWikiServices $services = null ): OATHAuthServices {
public static function getInstance( ?MediaWikiServices $services = null ): OATHAuthServices {
return new self(
$services ?? MediaWikiServices::getInstance(),
);

View file

@ -123,7 +123,7 @@ class OATHUser {
*
* @param IModule|null $module
*/
public function setModule( IModule $module = null ) {
public function setModule( ?IModule $module = null ) {
$this->module = $module;
}

View file

@ -231,7 +231,7 @@ class OATHManage extends SpecialPage {
return $modulePanel;
}
private function addCustomContent( IModule $module, PanelLayout $panel = null ): void {
private function addCustomContent( IModule $module, ?PanelLayout $panel = null ): void {
$form = $module->getManageForm(
$this->action,
$this->authUser,