Updated to fix time issues