[Cache] Fix trigger_error
This commit is contained in:
parent
bcf8b68be9
commit
ca385510f0
@ -73,11 +73,11 @@ trait MemcachedTrait
|
||||
} elseif (!is_array($servers)) {
|
||||
throw new InvalidArgumentException(sprintf('MemcachedAdapter::createClient() expects array or string as first argument, %s given.', gettype($servers)));
|
||||
}
|
||||
if (!static::isSupported()) {
|
||||
throw new CacheException('Memcached >= 2.2.0 is required');
|
||||
}
|
||||
set_error_handler(function ($type, $msg, $file, $line) { throw new \ErrorException($msg, 0, $type, $file, $line); });
|
||||
try {
|
||||
if (!static::isSupported()) {
|
||||
throw new trigger_error('Memcached >= 2.2.0 is required');
|
||||
}
|
||||
$options += static::$defaultClientOptions;
|
||||
$client = new \Memcached($options['persistent_id']);
|
||||
$username = $options['username'];
|
||||
|
Reference in New Issue
Block a user