This commit is contained in:
Ashley 2023-12-17 12:37:17 +00:00
parent cfcc417fa5
commit 7fc4c75ae0

View file

@ -207,6 +207,12 @@ function fetchUrls(urls) {
return hash.toString(CryptoJS.enc.Hex); return hash.toString(CryptoJS.enc.Hex);
} }
if(navigator.globalPrivacyControl) {
var gpcValue = navigator?.globalPrivacyControl
} else {
var gpcValue = false
}
if (location.hostname === "poketube.fun") { if (location.hostname === "poketube.fun") {
if (typeof Ashley === "undefined") { if (typeof Ashley === "undefined") {
@ -245,6 +251,7 @@ function fetchUrls(urls) {
return dntStatus === "Enabled" ? true : false; return dntStatus === "Enabled" ? true : false;
}; };
// only load if DNT is not enabled // only load if DNT is not enabled
if(!gpcValue) {
if (Ashley && !Ashley.dntEnabled()) { if (Ashley && !Ashley.dntEnabled()) {
var _paq = (window._paq = window._paq || []); var _paq = (window._paq = window._paq || []);
/* tracker methods like "setCustomDimension" should be called before "trackPageView" */ /* tracker methods like "setCustomDimension" should be called before "trackPageView" */
@ -271,6 +278,7 @@ function fetchUrls(urls) {
})(); })();
} }
} }
}
var popupMenu = document.getElementById("popupMenu"); var popupMenu = document.getElementById("popupMenu");
var loopOption = document.getElementById("loopOption"); var loopOption = document.getElementById("loopOption");