mirror of
https://github.com/He4eT/elseifplayer.git
synced 2026-05-05 01:17:22 +00:00
goatCounter: suppress some errors when script is blocked by some adblocker
This commit is contained in:
parent
fae4b09483
commit
26cebc2596
1 changed files with 2 additions and 0 deletions
|
|
@ -31,6 +31,8 @@
|
||||||
<script>
|
<script>
|
||||||
window.goatcounter = { no_onload: true }
|
window.goatcounter = { no_onload: true }
|
||||||
window.addEventListener('hashchange', _ => {
|
window.addEventListener('hashchange', _ => {
|
||||||
|
if (!window.goatcounter.count) return void null
|
||||||
|
|
||||||
window.goatcounter.count({
|
window.goatcounter.count({
|
||||||
path: location.pathname + location.hash
|
path: location.pathname + location.hash
|
||||||
})
|
})
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue