Upgrade button now hidden if no upgrades are available
fixed error with totime / fromtime being NaN / undefined