]> git.mxchange.org Git - friendica.git/blobdiff - src/Core/Cache/AbstractCacheDriver.php
Merge pull request #6612 from MrPetovan/bug/6605-cache-config-adapter-connection
[friendica.git] / src / Core / Cache / AbstractCacheDriver.php
index 1cdecf6ceb0ce6ff9473bdc8f0a8f4647e600298..13993385ad992d9dd7863630179a27a0e7dfad1c 100644 (file)
@@ -14,13 +14,14 @@ use Friendica\BaseObject;
 abstract class AbstractCacheDriver extends BaseObject
 {
        /**
-        * @param string $key   The original key
-        * @return string               The cache key used for the cache
+        * @param string $key The original key
+        * @return string        The cache key used for the cache
+        * @throws \Exception
         */
        protected function getCacheKey($key)
        {
                // We fetch with the hostname as key to avoid problems with other applications
-               return self::getApp()->get_hostname() . ":" . $key;
+               return self::getApp()->getHostName() . ":" . $key;
        }
 
        /**
@@ -34,7 +35,7 @@ abstract class AbstractCacheDriver extends BaseObject
                } else {
                        // Keys are prefixed with the node hostname, let's remove it
                        array_walk($keys, function (&$value) {
-                               $value = preg_replace('/^' . self::getApp()->get_hostname() . ':/', '', $value);
+                               $value = preg_replace('/^' . self::getApp()->getHostName() . ':/', '', $value);
                        });
 
                        sort($keys);