Fixed bug where time is initialized improperly