Replaced mktime to time