From b2cf3844ccf800971832f205caa50d478c3fd2ab Mon Sep 17 00:00:00 2001 From: marcrobledo Date: Fri, 4 May 2018 11:38:44 +0200 Subject: [PATCH] trying to fix PWA --- .nojekyll | 0 RomPatcher.js | 4 +++- 2 files changed, 3 insertions(+), 1 deletion(-) create mode 100644 .nojekyll diff --git a/.nojekyll b/.nojekyll new file mode 100644 index 0000000..e69de29 diff --git a/RomPatcher.js b/RomPatcher.js index a5629e8..ee9cb6b 100644 --- a/RomPatcher.js +++ b/RomPatcher.js @@ -10,6 +10,8 @@ function el(e){return document.getElementById(e)} /* initialize app */ addEvent(window,'load',function(){ /* service worker */ + if(location.protocol==='http:') + location.href=window.location.href.replace('http:','https:'); if('serviceWorker' in navigator) navigator.serviceWorker.register('_cache_service_worker.js'); @@ -95,7 +97,7 @@ function isHeadered(fileSize,headerSize){return isPowerOfTwo(fileSize-headerSize function updateChecksums(file){ - el('rom-info').style.display='flex'; + //el('rom-info').style.display='flex'; sha1(file); var crc32str=crc32(file).toString(16);