20 private int $migrationStage;
23 parent::__construct(
'Unusedimages' );
48 $tables = [
'image' ];
49 $nameField =
'img_name';
50 $timestampField =
'img_timestamp';
54 $tables = [
'file',
'filerevision' ];
55 $nameField =
'file_name';
56 $timestampField =
'fr_timestamp';
57 $extraConds = [
'file_deleted' => 0 ];
58 $extraJoins = [
'filerevision' => [
'JOIN',
'file_latest = fr_id' ] ];
62 'tables' => array_merge( $tables, [
'imagelinks' ] ),
65 'title' => $nameField,
66 'value' => $timestampField,
68 'conds' => array_merge( [
'il_to' =>
null ], $extraConds ),
69 'join_conds' => array_merge(
70 [
'imagelinks' => [
'LEFT JOIN',
'il_to = ' . $nameField ] ],
77 $retval[
'tables'] = [
'image',
'page',
'categorylinks',
79 $retval[
'conds'][
'page_namespace'] =
NS_FILE;
80 $retval[
'conds'][
'cl_from'] =
null;
81 $retval[
'conds'][] = $nameField .
' = page_title';
82 $retval[
'join_conds'][
'categorylinks'] = [
83 'LEFT JOIN',
'cl_from = page_id' ];
84 $retval[
'join_conds'][
'imagelinks'] = [
85 'LEFT JOIN',
'il_to = page_title' ];
100 'unusedimagestext-categorizedimgisused'
103 return $this->
msg(
'unusedimagestext' )->parseAsBlock();
108 return 'maintenance';
116class_alias( SpecialUnusedImages::class,
'SpecialUnusedImages' );
const SCHEMA_COMPAT_READ_OLD
A class containing constants representing the names of configuration variables.
const CountCategorizedImagesAsUsed
Name constant for the CountCategorizedImagesAsUsed setting, for use with Config::get()
const FileSchemaMigrationStage
Name constant for the FileSchemaMigrationStage setting, for use with Config::get()
Variant of QueryPage which uses a gallery to output results, thus suited for reports generating image...
setDatabaseProvider(IConnectionProvider $databaseProvider)
getConfig()
Shortcut to get main config object.
msg( $key,... $params)
Wrapper around wfMessage that sets the current context.