Skip to content

Commit

Permalink
[Continuation] Changed the GC::mark() method so as to get the current…
Browse files Browse the repository at this point in the history
… timestamp for each marker. (Issue piece#4)
  • Loading branch information
iteman committed Sep 18, 2012
1 parent 7b8af23 commit 1011e48
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/Piece/Flow/Continuation/GC.php
Expand Up @@ -98,14 +98,13 @@ public function isMarked($pageFlowInstanceID)
*/
public function mark()
{
$thresholdTime = time();
reset($this->markers);
while (list($pageFlowInstanceID, $marker) = each($this->markers)) {
if ($marker['swept']) {
continue;
}

$this->markers[$pageFlowInstanceID]['shouldSweep'] = $thresholdTime - $marker['mtime'] > $this->expirationTime;
$this->markers[$pageFlowInstanceID]['shouldSweep'] = time() - $marker['mtime'] > $this->expirationTime;
}
}

Expand Down

0 comments on commit 1011e48

Please sign in to comment.