Remove dependency on JavaScript Date because it does not behave the same on all platforms.