Merge "Add .pipeline/ with dev image variant"
[lhc/web/wiklou.git] / includes / page / PageArchive.php
index d69a433..8b2ff6b 100644 (file)
@@ -461,7 +461,7 @@ class PageArchive {
                $logEntry->setPerformer( $user );
                $logEntry->setTarget( $this->title );
                $logEntry->setComment( $comment );
-               $logEntry->setTags( $tags );
+               $logEntry->addTags( $tags );
                $logEntry->setParameters( [
                        ':assoc:count' => [
                                'revisions' => $textRestored,
@@ -756,10 +756,14 @@ class PageArchive {
 
                        Hooks::run( 'ArticleUndelete',
                                [ &$this->title, $created, $comment, $oldPageId, $restoredPages ] );
+
                        if ( $this->title->getNamespace() == NS_FILE ) {
-                               DeferredUpdates::addUpdate(
-                                       new HTMLCacheUpdate( $this->title, 'imagelinks', 'file-restore' )
+                               $job = HTMLCacheUpdateJob::newForBacklinks(
+                                       $this->title,
+                                       'imagelinks',
+                                       [ 'causeAction' => 'file-restore' ]
                                );
+                               JobQueueGroup::singleton()->lazyPush( $job );
                        }
                }