X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=maintenance%2Fundelete.php;h=e9b2abd0f91b9e509c1c55db5c1b14277337c1e1;hb=8641df974d1a030f7b7fad1e8e45e0f51f9816e1;hp=c2d5c2c2486a39278b1362706e422bddfc41aa08;hpb=a5be382adfdad4678eec18413c6a118cb3284daf;p=lhc%2Fweb%2Fwiklou.git diff --git a/maintenance/undelete.php b/maintenance/undelete.php index c2d5c2c248..e9b2abd0f9 100644 --- a/maintenance/undelete.php +++ b/maintenance/undelete.php @@ -41,7 +41,7 @@ class Undelete extends Maintenance { $title = Title::newFromText( $pageName ); if ( !$title ) { - $this->error( "Invalid title", true ); + $this->fatalError( "Invalid title" ); } if ( $user === false ) { $wgUser = User::newSystemUser( 'Command line script', [ 'steal' => true ] ); @@ -49,7 +49,7 @@ class Undelete extends Maintenance { $wgUser = User::newFromName( $user ); } if ( !$wgUser ) { - $this->error( "Invalid username", true ); + $this->fatalError( "Invalid username" ); } $archive = new PageArchive( $title, RequestContext::getMain()->getConfig() ); $this->output( "Undeleting " . $title->getPrefixedDBkey() . '...' ); @@ -58,5 +58,5 @@ class Undelete extends Maintenance { } } -$maintClass = "Undelete"; +$maintClass = Undelete::class; require_once RUN_MAINTENANCE_IF_MAIN;