]> git.mxchange.org Git - friendica.git/commitdiff
Add hostname prefix in MemcachedCacheDriver
authorHypolite Petovan <mrpetovan@gmail.com>
Thu, 19 Apr 2018 03:36:23 +0000 (23:36 -0400)
committerHypolite Petovan <mrpetovan@gmail.com>
Thu, 19 Apr 2018 03:36:23 +0000 (23:36 -0400)
src/Core/Cache/MemcachedCacheDriver.php

index d6b8d4ad5808146d00d9b8110c30770eaf019834..78a4a6bdfe28c8fd477afd5f8ac37ad23be61337 100644 (file)
@@ -50,7 +50,7 @@ class MemcachedCacheDriver extends BaseObject implements ICacheDriver
        {
                // We store with the hostname as key to avoid problems with other applications
                return $this->memcached->set(
-                       self::getApp()->get_hostname() . ":" . $key,
+                       self::getApp()->get_hostname() . ':' . $key,
                        $value,
                        time() + $duration
                );
@@ -58,7 +58,9 @@ class MemcachedCacheDriver extends BaseObject implements ICacheDriver
 
        public function delete($key)
        {
-               return $this->memcached->delete($key);
+               $return = $this->memcached->delete(self::getApp()->get_hostname() . ':' . $key);
+
+               return $return;
        }
 
        public function clear()