mirror of
https://github.com/Universal-Omega/PortableInfobox.git
synced 2024-12-04 20:59:08 +00:00
XW-2415 | set title for RefreshLinksForTitleTask
This commit is contained in:
parent
3b704769ff
commit
e9dc03726d
|
@ -34,18 +34,17 @@ class ApiQueryPortableInfobox extends ApiQueryBase {
|
||||||
$this->sourceLabelsFallback( $infobox, $articleTitle );
|
$this->sourceLabelsFallback( $infobox, $articleTitle );
|
||||||
|
|
||||||
$pageSet->getResult()->addValue( [ 'query', 'pages', $id, 'infoboxes', $count ], 'id', $count );
|
$pageSet->getResult()->addValue( [ 'query', 'pages', $id, 'infoboxes', $count ], 'id', $count );
|
||||||
|
|
||||||
$pageSet->getResult()->setIndexedTagName( $sl, "sourcelabels" );
|
$pageSet->getResult()->setIndexedTagName( $sl, "sourcelabels" );
|
||||||
$pageSet->getResult()->addValue(
|
$pageSet->getResult()->addValue(
|
||||||
[ 'query', 'pages', $id, 'infoboxes', $count ], 'sourcelabels', $sl
|
[ 'query', 'pages', $id, 'infoboxes', $count ], 'sourcelabels', $sl
|
||||||
);
|
);
|
||||||
|
|
||||||
// TODO is this even needed? Seems to work without this code
|
|
||||||
if ( isset( $infobox[ 'sourcetypes' ] ) ) {
|
if ( isset( $infobox[ 'sourcetypes' ] ) ) {
|
||||||
$pageSet->getResult()->addValue(
|
$pageSet->getResult()->addValue(
|
||||||
[ 'query', 'pages', $id, 'infoboxes', $count ], 'sourcetypes', $infobox[ 'sourcetypes' ]
|
[ 'query', 'pages', $id, 'infoboxes', $count ], 'sourcetypes', $infobox[ 'sourcetypes' ]
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -65,6 +64,7 @@ class ApiQueryPortableInfobox extends ApiQueryBase {
|
||||||
Wikia\Logger\WikiaLogger::instance()->info( 'Portable Infobox ApiQuery sourcelabels fallback' );
|
Wikia\Logger\WikiaLogger::instance()->info( 'Portable Infobox ApiQuery sourcelabels fallback' );
|
||||||
|
|
||||||
$task = new Wikia\Tasks\Tasks\RefreshLinksForTitleTask();
|
$task = new Wikia\Tasks\Tasks\RefreshLinksForTitleTask();
|
||||||
|
$task->setTitle( $title );
|
||||||
$task->title( $title );
|
$task->title( $title );
|
||||||
$task->call( 'refresh' );
|
$task->call( 'refresh' );
|
||||||
$task->wikiId( $wgCityId );
|
$task->wikiId( $wgCityId );
|
||||||
|
|
Loading…
Reference in a new issue