// Const for getStdin()
const STDIN_ALL = 'all';
- // Array of desired/allowed params
+ /**
+ * Array of desired/allowed params
+ * @var array[]
+ * @phan-var array<string,array{desc:string,require:bool,withArg:string,shortName:string,multiOccurrence:bool}>
+ */
protected $mParams = [];
// Array of mapping short parameters to long ones
*/
protected $mBatchSize = null;
- // Generic options added by addDefaultParams()
+ /**
+ * Generic options added by addDefaultParams()
+ * @var array[]
+ * @phan-var array<string,array{desc:string,require:bool,withArg:string,shortName:string,multiOccurrence:bool}>
+ */
private $mGenericParameters = [];
- // Generic options which might or not be supported by the script
+ /**
+ * Generic options which might or not be supported by the script
+ * @var array[]
+ * @phan-var array<string,array{desc:string,require:bool,withArg:string,shortName:string,multiOccurrence:bool}>
+ */
private $mDependantParameters = [];
/**
+ $wgProfiler
+ [ 'threshold' => $wgProfileLimit ]
);
- $profiler->setTemplated( true );
+ $profiler->setAllowOutput();
Profiler::replaceStubInstance( $profiler );
}
*/
protected function afterFinalSetup() {
if ( defined( 'MW_CMDLINE_CALLBACK' ) ) {
+ // @phan-suppress-next-line PhanUndeclaredConstant
call_user_func( MW_CMDLINE_CALLBACK );
}
}
$res = $dbw->select( 'content', 'content_address', [], __METHOD__, [ 'DISTINCT' ] );
$blobStore = MediaWikiServices::getInstance()->getBlobStore();
foreach ( $res as $row ) {
+ // @phan-suppress-next-line PhanUndeclaredMethod
$textId = $blobStore->getTextIdFromAddress( $row->content_address );
if ( $textId ) {
$cur[] = $textId;
$title = $titleObj->getPrefixedDBkey();
$this->output( "$title..." );
# Update searchindex
- $u = new SearchUpdate( $pageId, $titleObj->getText(), $rev->getContent() );
+ $u = new SearchUpdate( $pageId, $titleObj, $rev->getContent() );
$u->doUpdate();
$this->output( "\n" );
}