fixed time not getting saved bug