forked from leftypol/leftypol
MemcacheCacheDriver.php: fix error check
This commit is contained in:
parent
7aae8be1ae
commit
3c9c86901a
1 changed files with 2 additions and 2 deletions
|
|
@ -39,12 +39,12 @@ class MemcachedCacheDriver implements CacheDriver {
|
|||
|
||||
if (!$found_in_curr) {
|
||||
if (!empty($current_servers)) {
|
||||
if ($this->inner->resetServerList()) {
|
||||
if (!$this->inner->resetServerList()) {
|
||||
$err = $this->inner->getResultMessage();
|
||||
throw new \RuntimeException("Unable to reset the memcached server list: '$err'");
|
||||
}
|
||||
}
|
||||
if ($this->inner->addServer($server_uri, $server_port, $server_weight)) {
|
||||
if (!$this->inner->addServer($server_uri, $server_port, $server_weight)) {
|
||||
$err = $this->inner->getResultMessage();
|
||||
throw new \RuntimeException("Unable to add memcached servers: '$err'");
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue