mirror of
https://gitee.com/fastadminnet/framework.git
synced 2026-07-01 20:52:48 +08:00
修复inc方法
This commit is contained in:
5
library/think/cache/driver/Memcache.php
vendored
5
library/think/cache/driver/Memcache.php
vendored
@@ -113,7 +113,10 @@ class Memcache extends Driver
|
||||
public function inc($name, $step = 1)
|
||||
{
|
||||
$key = $this->getCacheKey($name);
|
||||
return $this->handler->increment($key, $step);
|
||||
if( $this->has($name) ){
|
||||
return $this->handler->increment($key, $step);
|
||||
}
|
||||
return $this->handler->set($key, $step);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user