mirror of
https://gitee.com/fastadminnet/framework.git
synced 2026-07-09 16:12:49 +08:00
Cache类的tag方法支持追加缓存标识
This commit is contained in:
7
library/think/cache/Driver.php
vendored
7
library/think/cache/Driver.php
vendored
@@ -94,8 +94,11 @@ abstract class Driver
|
||||
return $this;
|
||||
} else {
|
||||
$key = 'tag_' . md5($name);
|
||||
$value = is_array($keys) ? implode(',', $keys) : $keys;
|
||||
$this->set($key, $value);
|
||||
if (is_string($keys)) {
|
||||
$keys = explode(',', $keys);
|
||||
}
|
||||
$value = array_unique(array_merge($this->getTagItem($name), $keys));
|
||||
$this->set($key, implode(',', $value));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user