X-Git-Url: https://git.heureux-cyclage.org/?p=lhc%2Fweb%2Fwiklou.git;a=blobdiff_plain;f=includes%2Ffilerepo%2Ffile%2FFile.php;h=73b08e6a34c7498701600365f5884a88429290a0;hp=0d5776bba2a9606cbf8d5849d6f67353b6bc536a;hb=9e8439e79d67788916d488f645108f79016d9aca;hpb=75e2607211b30103417d73a780498b9d27537b62 diff --git a/includes/filerepo/file/File.php b/includes/filerepo/file/File.php index 0d5776bba2..73b08e6a34 100644 --- a/includes/filerepo/file/File.php +++ b/includes/filerepo/file/File.php @@ -1467,13 +1467,15 @@ abstract class File implements IDBAccessObject { // Delete thumbnails and refresh file metadata cache $this->purgeCache(); $this->purgeDescription(); - // Purge cache of all pages using this file $title = $this->getTitle(); if ( $title ) { - DeferredUpdates::addUpdate( - new HTMLCacheUpdate( $title, 'imagelinks', 'file-purge' ) + $job = HTMLCacheUpdateJob::newForBacklinks( + $title, + 'imagelinks', + [ 'causeAction' => 'file-purge' ] ); + JobQueueGroup::singleton()->lazyPush( $job ); } } @@ -2040,7 +2042,7 @@ abstract class File implements IDBAccessObject { * Get the URL of the image description page. May return false if it is * unknown or not applicable. * - * @return string + * @return string|bool */ function getDescriptionUrl() { if ( $this->repo ) {