diff --git a/js/script.js b/js/script.js index 5a581c5..6680f14 100644 --- a/js/script.js +++ b/js/script.js @@ -1,4 +1,7 @@ -if (location.protocol !== "https" && !location.hostname.startsWith('localhost')) location.protocol = "https"; +if (location.host.indexOf("localhost") < 0 && location.protocol.toLowerCase() !== "https:") { + const url = `https://${location.host}`; + location.replace(url); +} import "./color.js"; import "./shell.js";