From cc4ca3e86d3e485ff310f1a17b376f351387160a Mon Sep 17 00:00:00 2001 From: Aaron Schulz Date: Mon, 21 Sep 2015 16:25:47 -0700 Subject: [PATCH] Removed deprecated $wgDeferredUpdateList Change-Id: I7072ad3b34dd9a0726df6d1c044616c3b4bcd79f --- RELEASE-NOTES-1.26 | 1 + includes/Setup.php | 6 ------ includes/deferred/DeferredUpdates.php | 9 +++------ tests/phpunit/includes/parser/NewParserTest.php | 1 - 4 files changed, 4 insertions(+), 13 deletions(-) diff --git a/RELEASE-NOTES-1.26 b/RELEASE-NOTES-1.26 index 13239de831..bf07b2056d 100644 --- a/RELEASE-NOTES-1.26 +++ b/RELEASE-NOTES-1.26 @@ -188,6 +188,7 @@ changes to languages because of Phabricator reports. are deprecated. Applications using those can work via the OAuth extension instead. New tokens types should not be added. * DatabaseBase::errorCount() was removed (unused). +* $wgDeferredUpdateList was removed. == Compatibility == diff --git a/includes/Setup.php b/includes/Setup.php index 479ce8c32a..e79d13ccfc 100644 --- a/includes/Setup.php +++ b/includes/Setup.php @@ -681,12 +681,6 @@ if ( !is_object( $wgAuth ) ) { */ $wgTitle = null; -/** - * @deprecated since 1.24 Use DeferredUpdates::addUpdate instead - * @var array - */ -$wgDeferredUpdateList = array(); - Profiler::instance()->scopedProfileOut( $ps_globals ); $ps_extensions = Profiler::instance()->scopedProfileIn( $fname . '-extensions' ); diff --git a/includes/deferred/DeferredUpdates.php b/includes/deferred/DeferredUpdates.php index b7e5b0a0b6..713ce70b3f 100644 --- a/includes/deferred/DeferredUpdates.php +++ b/includes/deferred/DeferredUpdates.php @@ -106,9 +106,7 @@ class DeferredUpdates { * prevent lock contention */ public static function doUpdates( $commit = '' ) { - global $wgDeferredUpdateList; - - $updates = array_merge( $wgDeferredUpdateList, self::$updates ); + $updates = self::$updates; while ( count( $updates ) ) { self::clearPendingUpdates(); @@ -131,7 +129,7 @@ class DeferredUpdates { } } - $updates = array_merge( $wgDeferredUpdateList, self::$updates ); + $updates = self::$updates; } } @@ -140,7 +138,6 @@ class DeferredUpdates { * want or need to call this. Unit tests need it though. */ public static function clearPendingUpdates() { - global $wgDeferredUpdateList; - $wgDeferredUpdateList = self::$updates = array(); + self::$updates = array(); } } diff --git a/tests/phpunit/includes/parser/NewParserTest.php b/tests/phpunit/includes/parser/NewParserTest.php index 0d2129b729..df7da98c62 100644 --- a/tests/phpunit/includes/parser/NewParserTest.php +++ b/tests/phpunit/includes/parser/NewParserTest.php @@ -106,7 +106,6 @@ class NewParserTest extends MediaWikiTestCase { $tmpGlobals['wgAdaptiveMessageCache'] = true; $tmpGlobals['wgUseDatabaseMessages'] = true; $tmpGlobals['wgLocaltimezone'] = 'UTC'; - $tmpGlobals['wgDeferredUpdateList'] = array(); $tmpGlobals['wgGroupPermissions'] = array( '*' => array( 'createaccount' => true, -- 2.20.1