X-Git-Url: http://git.heureux-cyclage.org/?a=blobdiff_plain;f=maintenance%2Fprotect.php;h=b47476a58c86198bf5242833421ef64766fb0b39;hb=693e9b2728d910c3c32affd2013f755fe22e03e3;hp=f6bb2532024ea2d2d79ec9502c805b76387aaad5;hpb=8bb5a6c461c31ee5ce6874548246fc2c520686f6;p=lhc%2Fweb%2Fwiklou.git diff --git a/maintenance/protect.php b/maintenance/protect.php index f6bb253202..b47476a58c 100644 --- a/maintenance/protect.php +++ b/maintenance/protect.php @@ -59,7 +59,7 @@ class Protect extends Maintenance { $user = User::newFromName( $userName ); } if ( !$user ) { - $this->error( "Invalid username", true ); + $this->fatalError( "Invalid username" ); } // @todo FIXME: This is reset 7 lines down. @@ -67,7 +67,7 @@ class Protect extends Maintenance { $t = Title::newFromText( $this->getArg() ); if ( !$t ) { - $this->error( "Invalid title", true ); + $this->fatalError( "Invalid title" ); } $restrictions = []; @@ -89,5 +89,5 @@ class Protect extends Maintenance { } } -$maintClass = "Protect"; +$maintClass = Protect::class; require_once RUN_MAINTENANCE_IF_MAIN;