Remove redundant onTransactionIdle() call from WikiPage::doPurge
authorAaron Schulz <aschulz@wikimedia.org>
Tue, 19 Jul 2016 20:51:55 +0000 (13:51 -0700)
committerAaron Schulz <aschulz@wikimedia.org>
Tue, 19 Jul 2016 20:51:55 +0000 (13:51 -0700)
Change-Id: I18b03ae6d2f865bbe7eb072c68b2648564ec4d6f

includes/page/WikiPage.php

index b64604e..dbc27a9 100644 (file)
@@ -1103,15 +1103,10 @@ class WikiPage implements Page, IDBAccessObject {
                        return false;
                }
 
-               $title = $this->mTitle;
-               wfGetDB( DB_MASTER )->onTransactionIdle( function() use ( $title ) {
-                       // Invalidate the cache in auto-commit mode
-                       $title->invalidateCache();
-               } );
-
+               $this->mTitle->invalidateCache();
                // Send purge after above page_touched update was committed
                DeferredUpdates::addUpdate(
-                       new CdnCacheUpdate( $title->getCdnUrls() ),
+                       new CdnCacheUpdate( $this->mTitle->getCdnUrls() ),
                        DeferredUpdates::PRESEND
                );