Skip to content

Commit

Permalink
feat: record time in fsm history
Browse files Browse the repository at this point in the history
  • Loading branch information
Fishdrowned committed Jul 12, 2016
1 parent 2341b1b commit 732a81c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/StateMachine.php
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ public function initAction(array $history = [])
$currentState = end($history);
return $this->currentState = $currentState['state'];
}
$this->history[] = ['action' => 'init', 'state' => $this->initState];
$this->history[] = ['time' => time(), 'action' => 'init', 'state' => $this->initState];
return $this->currentState = $this->initState;
}

Expand Down

0 comments on commit 732a81c

Please sign in to comment.