Skip to content

Commit 5afb92b

Browse files
committed
Fixed multiple item read on deleteItem
1 parent 8ae0275 commit 5afb92b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/phpFastCache/Core/StandardPsr6StructureTrait.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ public function clear()
155155
public function deleteItem($key)
156156
{
157157
$item = $this->getItem($key);
158-
if ($this->hasItem($key) && $this->driverDelete($item)) {
158+
if ($item->isHit() && $this->driverDelete($item)) {
159159
$item->setHit(false);
160160
CacheManager::$WriteHits++;
161161
/**

0 commit comments

Comments
 (0)