Siebrand has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/102649


Change subject: Replace deprecated Job::insert()
......................................................................

Replace deprecated Job::insert()

Change-Id: I37239b3628f69b0187a7c8c31a30698589509330
---
M CachedStat.php
1 file changed, 4 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TwnMainPage 
refs/changes/49/102649/1

diff --git a/CachedStat.php b/CachedStat.php
index bc752d7..05cd7d5 100644
--- a/CachedStat.php
+++ b/CachedStat.php
@@ -77,7 +77,8 @@
 
                if ( !is_array( $value ) ) {
                        if ( $this->onMiss !== 'update' ) {
-                               CachedStatJob::newJob( $this )->insert();
+                               $job = CachedStatJob::newJob( $this );
+                               JobQueueGroup::singleton()->push( $job );
 
                                return null;
                        } else {
@@ -89,7 +90,8 @@
                        // Useless
                        // DeferredUpdates::addUpdate( $this );
                        // Use jobqueue instead
-                       CachedStatJob::newJob( $this )->insert();
+                       $job = CachedStatJob::newJob( $this );
+                       JobQueueGroup::singleton()->push( $job );
                }
 
                return $value['v'];

-- 
To view, visit https://gerrit.wikimedia.org/r/102649
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I37239b3628f69b0187a7c8c31a30698589509330
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/TwnMainPage
Gerrit-Branch: master
Gerrit-Owner: Siebrand <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to