Fix time bugs.