aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBart Visscher <bartv@thisnet.nl>2014-05-08 18:11:29 +0200
committerBart Visscher <bartv@thisnet.nl>2014-05-08 18:11:29 +0200
commit88225db4af499a7e13fc62ceb8cd9de461878202 (patch)
tree24c4af38ba88bcb72352bc842984eaf99a266b2e
parent8ede209ea3ca4913f7d6d4447ff14439ab3cf1b7 (diff)
downloadnextcloud-server-88225db4af499a7e13fc62ceb8cd9de461878202.tar.gz
nextcloud-server-88225db4af499a7e13fc62ceb8cd9de461878202.zip
Memcached hasKey should test for success, the get can fail for other reasons.
One of the other failures is no running server.
-rw-r--r--lib/private/memcache/memcached.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/private/memcache/memcached.php b/lib/private/memcache/memcached.php
index 075828eebad..cd8e2e8d0b6 100644
--- a/lib/private/memcache/memcached.php
+++ b/lib/private/memcache/memcached.php
@@ -57,7 +57,7 @@ class Memcached extends Cache {
public function hasKey($key) {
self::$cache->get($this->getNamespace() . $key);
- return self::$cache->getResultCode() !== \Memcached::RES_NOTFOUND;
+ return self::$cache->getResultCode() === \Memcached::RES_SUCCESS;
}
public function remove($key) {