prevent location being just "#"

This commit is contained in:
Til Schmitter 2026-06-05 01:57:44 +02:00
parent 018268df43
commit 998a9b86a3

View file

@ -1404,7 +1404,7 @@ function hist_replace(url) {
function sethash(hv) {
if (window.history && history.replaceState) {
hist_replace(location.pathname + location.search + '#' + hv);
hist_replace(location.pathname + location.search + (hv ? '#' : '') + hv);
}
else {
location.hash = hv;