aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorUmherirrender <umherirrender_de.wp@web.de>2020-11-02 13:31:33 +0100
committerUmherirrender <umherirrender_de.wp@web.de>2020-11-02 13:31:33 +0100
commitde1b56caf739abfff268f3932133fc19db3ccc90 (patch)
tree62aa6d857e96ab3ab325cff3de56ecefab5f61bd
parent3173b984206ccd6c63b763ead940fe22705e0e18 (diff)
downloadmediawikicore-de1b56caf739abfff268f3932133fc19db3ccc90.tar.gz
mediawikicore-de1b56caf739abfff268f3932133fc19db3ccc90.zip
Replace deprecated wfGetCache
Change-Id: I082b95bf0dcf3625f3c71689e78643b55238b5f8
-rw-r--r--includes/cache/CacheHelper.php4
-rw-r--r--includes/specials/SpecialVersion.php2
2 files changed, 3 insertions, 3 deletions
diff --git a/includes/cache/CacheHelper.php b/includes/cache/CacheHelper.php
index 35c1cf7a2454..c2896637d03a 100644
--- a/includes/cache/CacheHelper.php
+++ b/includes/cache/CacheHelper.php
@@ -174,7 +174,7 @@ class CacheHelper implements ICacheHelper {
*/
protected function initCaching() {
if ( $this->cacheEnabled && $this->hasCached === null ) {
- $cachedChunks = wfGetCache( CACHE_ANYTHING )->get( $this->getCacheKeyString() );
+ $cachedChunks = ObjectCache::getInstance( CACHE_ANYTHING )->get( $this->getCacheKeyString() );
$this->hasCached = is_array( $cachedChunks );
$this->cachedChunks = $this->hasCached ? $cachedChunks : [];
@@ -250,7 +250,7 @@ class CacheHelper implements ICacheHelper {
*/
public function saveCache() {
if ( $this->cacheEnabled && $this->hasCached === false && !empty( $this->cachedChunks ) ) {
- wfGetCache( CACHE_ANYTHING )->set(
+ ObjectCache::getInstance( CACHE_ANYTHING )->set(
$this->getCacheKeyString(),
$this->cachedChunks,
$this->cacheExpiry
diff --git a/includes/specials/SpecialVersion.php b/includes/specials/SpecialVersion.php
index af03de03144a..1cc92d39e4aa 100644
--- a/includes/specials/SpecialVersion.php
+++ b/includes/specials/SpecialVersion.php
@@ -807,7 +807,7 @@ class SpecialVersion extends SpecialPage {
$this->coreId = $coreHeadSHA1;
}
}
- $cache = wfGetCache( CACHE_ANYTHING );
+ $cache = ObjectCache::getInstance( CACHE_ANYTHING );
$memcKey = $cache->makeKey(
'specialversion-ext-version-text', $extension['path'], $this->coreId
);