Skip to content

Commit 3e5b858

Browse files
committed
Reset $calls after getCalls()
1 parent f9fdfc8 commit 3e5b858

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/Symfony/Component/Cache/Adapter/TraceableAdapter.php

+5-1
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,11 @@ public function commit()
177177

178178
public function getCalls()
179179
{
180-
return $this->calls;
180+
try {
181+
return $this->calls;
182+
} finally {
183+
$this->calls = array();
184+
}
181185
}
182186

183187
private function start($name, $argument = null)

0 commit comments

Comments
 (0)