Mercurial > gemma
view client/src/lib/session.js @ 400:cb233a5a2ecd
fix: Fixed country validation on submit
Fixed wrong validation behaviour.
author | Thomas Junk <thomas.junk@intevation.de> |
---|---|
date | Tue, 14 Aug 2018 14:21:07 +0200 |
parents | 4bf2173748f3 |
children | 27502291e564 |
line wrap: on
line source
function sessionStillActive(expiresFromPastSession) { if (!expiresFromPastSession) return false; const now = Date.now(); const stillActive = now < expiresFromPastSession; return stillActive; } function toMillisFromString(timestring) { return timestring * 1000; } export { sessionStillActive, toMillisFromString };