diff options
author | James D. Forrester <jforrester@wikimedia.org> | 2024-10-15 19:57:34 -0400 |
---|---|---|
committer | James D. Forrester <jforrester@wikimedia.org> | 2024-10-16 13:30:12 -0400 |
commit | e7db78e8d6a3e4eb723bdd4985004492504f0b68 (patch) | |
tree | e284069a0f3ceafa52ecf0811c6d717621693c06 /maintenance | |
parent | 4acdea458f39f3491feb605001b52696086b1e7e (diff) | |
download | mediawikicore-e7db78e8d6a3e4eb723bdd4985004492504f0b68.tar.gz mediawikicore-e7db78e8d6a3e4eb723bdd4985004492504f0b68.zip |
Replace uses of deprecated ChangeTags static methods
Bug: T360664
Change-Id: I3363a225e54bb2cae01ba066d432a8b7b21933d2
Diffstat (limited to 'maintenance')
-rw-r--r-- | maintenance/deleteTag.php | 4 | ||||
-rw-r--r-- | maintenance/importImages.php | 5 |
2 files changed, 6 insertions, 3 deletions
diff --git a/maintenance/deleteTag.php b/maintenance/deleteTag.php index cc69cfc87aa3..bf25290b21d7 100644 --- a/maintenance/deleteTag.php +++ b/maintenance/deleteTag.php @@ -48,7 +48,7 @@ class DeleteTag extends Maintenance { ] ) ->where( [ 'ctd_id' => $tagId ] ) ->caller( __METHOD__ )->execute(); - ChangeTags::purgeTagCacheAll(); + $this->getServiceContainer()->getChangeTagsStore()->purgeTagCacheAll(); // Iterate over change_tag, deleting rows in batches $count = 0; @@ -74,7 +74,7 @@ class DeleteTag extends Maintenance { } while ( true ); $this->output( "The tag has been removed from $count revisions, deleting the tag itself...\n" ); - ChangeTags::deleteTagEverywhere( $tag ); + $this->getServiceContainer()->getChangeTagsStore()->deleteTagEverywhere( $tag ); $this->output( "Done.\n" ); } } diff --git a/maintenance/importImages.php b/maintenance/importImages.php index cdeeaeefe9d9..204fed4741a6 100644 --- a/maintenance/importImages.php +++ b/maintenance/importImages.php @@ -204,7 +204,10 @@ class ImportImages extends Maintenance { $license = $this->getOption( 'license', '' ); $sourceWikiUrl = $this->getOption( 'source-wiki-url' ); - $tags = in_array( ChangeTags::TAG_SERVER_SIDE_UPLOAD, ChangeTags::getSoftwareTags() ) + $tags = in_array( + ChangeTags::TAG_SERVER_SIDE_UPLOAD, + $this->getServiceContainer()->getChangeTagsStore()->getSoftwareTags() + ) ? [ ChangeTags::TAG_SERVER_SIDE_UPLOAD ] : []; |