Rework time logic