X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;ds=sidebyside;f=maintenance%2FcompareParsers.php;h=fe6e604d96104744a8db3fb31a815de6a6943e15;hb=a7064a0883ec6d715c8c8103efe777769a85437d;hp=e67c439baf8a45f3c6fe87aab31082e9562248c1;hpb=f0edb3e368a5fc69218d20f76f1538b68f37db42;p=lhc%2Fweb%2Fwiklou.git diff --git a/maintenance/compareParsers.php b/maintenance/compareParsers.php index e67c439baf..fe6e604d96 100644 --- a/maintenance/compareParsers.php +++ b/maintenance/compareParsers.php @@ -43,7 +43,7 @@ class CompareParsers extends DumpIterator { public function __construct() { parent::__construct(); $this->saveFailed = false; - $this->mDescription = "Run a file or dump with several parsers"; + $this->addDescription( 'Run a file or dump with several parsers' ); $this->addOption( 'parser1', 'The first parser to compare.', true, true ); $this->addOption( 'parser2', 'The second parser to compare.', true, true ); $this->addOption( 'tidy', 'Run tidy on the articles.', false, false ); @@ -97,7 +97,7 @@ class CompareParsers extends DumpIterator { if ( $this->hasOption( 'tidy' ) ) { global $wgUseTidy; if ( !$wgUseTidy ) { - $this->error( 'Tidy was requested but $wgUseTidy is not set in LocalSettings.php', true ); + $this->fatalError( 'Tidy was requested but $wgUseTidy is not set in LocalSettings.php' ); } $this->options->setTidy( true ); } @@ -185,5 +185,5 @@ class CompareParsers extends DumpIterator { } } -$maintClass = "CompareParsers"; +$maintClass = CompareParsers::class; require_once RUN_MAINTENANCE_IF_MAIN;