Skip to content

Commit

Permalink
fix: replace url
Browse files Browse the repository at this point in the history
  • Loading branch information
IronKinoko committed Oct 21, 2023
1 parent c19eb6c commit afb4b82
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/adapter/common/defineIframePlayer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,9 @@ export function defineIframePlayer(config: Config) {
}

function setActive(url: string) {
if (window.location.href === url) return
window.history.pushState(window.history.state, '', url)
if (window.location.href !== url) {
window.history.pushState(window.history.state, '', url)
}
config.setActive(url)
createIframeReadyToChangeIframeSrc(url)
}
Expand Down

0 comments on commit afb4b82

Please sign in to comment.