Update sw.js

This commit is contained in:
Harsh Khandeparkar
2019-03-27 20:17:40 +00:00
committed by GitHub
parent 503973ee12
commit 13e410d5bf

View File

@@ -4,7 +4,7 @@ request.send(null);
const meta = JSON.parse(request.responseText).metadata,
ver = meta.version,
betaVer = meta.betaVersion;
const version = (window.location.indexOf('beta') == 0) ? betaVer : ver;
const version = (self.location.toString().indexOf('beta') == 0 || self.location.toString().includes('localhost') || self.location.toString().includes('127.0.0.1')) ? betaVer : ver;
const staticCacheName = `image-sequencer-static-v${version}`,
is