diff --git a/public/offline.html b/public/offline.html index 0f3160a..02fefda 100644 --- a/public/offline.html +++ b/public/offline.html @@ -34,7 +34,11 @@ function go() { if (navigator.onLine) { - windowProxy = window.open("/#/?migrate=1", "_blank"); + let url = "/#/?migrate=1"; + if (!url.includes("://")) { + url = window.location.protocol + "//" + url; + } + windowProxy = window.open(url, "_blank"); } } @@ -68,7 +72,11 @@ } else if (data !== null && data.cmd == "migrationDone") { if (windowProxy) { windowProxy.close(); - window.location.href = "/#/"; + let url = "/#/"; + if (!url.includes("://")) { + url = window.location.protocol + "//" + url; + } + window.location.href = url; } } } catch (error) {