Skip to content

Commit

Permalink
Fix small issue with browser history
Browse files Browse the repository at this point in the history
  • Loading branch information
stefandesu committed Aug 8, 2024
1 parent 98449f4 commit ead3e14
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,9 @@ addEventListener("popstate", initializeFromUrl)
function updateUrl({ ppn } = {}) {
const hash = window.location.hash
const urlParams = new URLSearchParams(window.location.search)
if ((urlParams.get("ppn") || null) === ppn) {
return
}
if (ppn) {
urlParams.set("ppn", ppn)
} else {
Expand Down

0 comments on commit ead3e14

Please sign in to comment.