fixed bug with time