Skip to content
Snippets Groups Projects
Unverified Commit 5d2ea72f authored by Jaime Pérez Crespo's avatar Jaime Pérez Crespo
Browse files

Check if we have Memcached available first, instead of the deprecated Memcache (without "d")

parent 1617f204
No related branches found
No related tags found
No related merge requests found
......@@ -310,12 +310,12 @@ class Memcache
*/
private static function loadMemcacheServerGroup(array $group)
{
if (class_exists(\Memcache::class)) {
$memcache = new \Memcache();
self::$extension = strtolower(\Memcache::class);
} elseif (class_exists(\Memcached::class)) {
if (class_exists(\Memcached::class)) {
$memcache = new \Memcached();
self::$extension = strtolower(\Memcached::class);
} elseif (class_exists(\Memcache::class)) {
$memcache = new \Memcache();
self::$extension = strtolower(\Memcache::class);
} else {
throw new \Exception(
'Missing Memcached implementation. You must install either the Memcache or Memcached extension.'
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment