diff --git a/index.html b/index.html
index 801109b..5f43abe 100644
--- a/index.html
+++ b/index.html
@@ -1069,7 +1069,8 @@ function writeHash(){
const p=new URLSearchParams();
KEYS.forEach(k=>{ if (S[k]!==DEFAULT[k]) p.set(k,S[k]); });
hashLock=true;
- history.replaceState(null,"", p.toString()? "#"+p.toString() : location.pathname);
+ const baseUrl = window.location.pathname + window.location.search;
+ history.replaceState(null,"", p.toString()? "#"+p.toString() : baseUrl);
setTimeout(()=>hashLock=false,0);
}
function readHash(){