diff --git a/src/util/api.js b/src/util/api.js index 958206e..d38acd4 100644 --- a/src/util/api.js +++ b/src/util/api.js @@ -121,6 +121,14 @@ async function syncSplash() { let load = (async () => { const splash = await callV2('GET', '/splash'); await Token.set('splash', JSON.stringify(splash)); + + const now = Date.parse(new Date()) / 1000; + if((splash.start_time && splash.start_time > now) || + (splash.end_time && now > splash.end_time)) { + + return null; + } + return splash; })();