Fix bug: lock seconds left never decreases

lazy val is evaluated when cache is set, so change it to def
Remove unnecessary use of identity