From 5da8bd962a47a3188b2d94b20bc6448a49a8189b Mon Sep 17 00:00:00 2001 From: thinkphp Date: Thu, 29 Jun 2017 16:29:49 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=B9=E8=BF=9B=E7=BC=93=E5=AD=98=E6=A0=87?= =?UTF-8?q?=E7=AD=BE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- library/think/cache/Driver.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/library/think/cache/Driver.php b/library/think/cache/Driver.php index 688507a8..ab48bdd6 100644 --- a/library/think/cache/Driver.php +++ b/library/think/cache/Driver.php @@ -170,8 +170,9 @@ abstract class Driver $key = 'tag_' . md5($this->tag); $this->tag = null; if ($this->has($key)) { - $value = $this->get($key); - $value .= ',' . $name; + $value = explode(',', $this->get($key)); + $value[] = $name; + $value = implode(',', array_unique($value)); } else { $value = $name; }