From 6c49ca08bf467198f1f34d1218041c9cf3628515 Mon Sep 17 00:00:00 2001 From: Captain ALM Date: Sat, 30 Jul 2022 22:57:41 +0100 Subject: [PATCH] . --- index.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/index.js b/index.js index c264d21..76a066e 100644 --- a/index.js +++ b/index.js @@ -99,7 +99,6 @@ function PushHistory(url) { sort: document.getElementById("so-sort").value }, "", url); console.log("PUSH") - ReplaceHistory(url) s = false } } @@ -143,7 +142,7 @@ function ToggleTheme() { function SetupJSHPL(){ if (window.history) { if (window.history.pushState && window.history.replaceState) { - window.addEventListener("load", cReplaceHistory) + document.addEventListener("DOMContentLoaded", cReplaceHistory) window.addEventListener("popstate", HandleHistoryPop) } }