X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=maintenance%2FpreprocessDump.php;h=ec759dae334dec4d1523882c42f63a0d7bdf1da5;hb=f724e1dfba13c74b82d1f12442b08e8798bea82b;hp=f0e5a6c8213b9a26c9820e2c5e0c98034bde2bb1;hpb=ed6bb98f1c40ef2a2de1a570dd209f7af1d5ea5b;p=lhc%2Fweb%2Fwiklou.git diff --git a/maintenance/preprocessDump.php b/maintenance/preprocessDump.php index f0e5a6c821..ec759dae33 100644 --- a/maintenance/preprocessDump.php +++ b/maintenance/preprocessDump.php @@ -26,7 +26,7 @@ */ use MediaWiki\MediaWikiServices; -use MediaWiki\Storage\RevisionRecord; +use MediaWiki\Revision\RevisionRecord; require_once __DIR__ . '/dumpIterator.php'; @@ -41,6 +41,8 @@ class PreprocessDump extends DumpIterator { /* Variables for dressing up as a parser */ public $mTitle = 'PreprocessDump'; public $mPPNodeCount = 0; + /** @var Preprocessor */ + public $mPreprocessor; public function getStripList() { $parser = MediaWikiServices::getInstance()->getParser(); @@ -88,6 +90,8 @@ class PreprocessDump extends DumpIterator { if ( $content->getModel() !== CONTENT_MODEL_WIKITEXT ) { return; } + /** @var WikitextContent $content */ + '@phan-var WikitextContent $content'; try { $this->mPreprocessor->preprocessToObj( strval( $content->getText() ), 0 );