fixed the date and time bug