X-Git-Url: https://git.heureux-cyclage.org/?p=lhc%2Fweb%2Fwiklou.git;a=blobdiff_plain;f=maintenance%2FimportDump.php;h=6640148a28657b2dd28e1d85bce68e4f3309e725;hp=c2c5ccf40e977af7bedbe91bbacbf745665de6aa;hb=af80076034fb734d652eb043c523c1d8df974e51;hpb=1e7da67c180092b1c2effc77f590cc160127ce72 diff --git a/maintenance/importDump.php b/maintenance/importDump.php index c2c5ccf40e..6640148a28 100644 --- a/maintenance/importDump.php +++ b/maintenance/importDump.php @@ -41,7 +41,18 @@ class BackupReader extends Maintenance { public $uploads = false; protected $uploadCount = 0; public $imageBasePath = false; + /** @var array|false */ public $nsFilter = false; + /** @var bool|resource */ + public $stderr; + /** @var callable|null */ + protected $importCallback; + /** @var callable|null */ + protected $logItemCallback; + /** @var callable|null */ + protected $uploadCallback; + /** @var int */ + protected $startTime; function __construct() { parent::__construct(); @@ -210,6 +221,7 @@ TEXT } $this->uploadCount++; // $this->report(); + // @phan-suppress-next-line PhanUndeclaredMethod $this->progress( "upload: " . $revision->getFilename() ); if ( !$this->dryRun ) { @@ -314,7 +326,7 @@ TEXT $statusRootPage = $importer->setTargetRootPage( $this->getOption( 'rootpage' ) ); if ( !$statusRootPage->isGood() ) { // Die here so that it doesn't print "Done!" - $this->fatalError( $statusRootPage->getMessage()->text() ); + $this->fatalError( $statusRootPage->getMessage( false, false, 'en' )->text() ); return false; } }