Prevent getquanty to be loaded twice

This commit is contained in:
Amauri CHAMPEAUX 2021-04-30 09:56:21 +02:00
parent c5ea5da466
commit f7a12bcb9a
1 changed files with 6 additions and 0 deletions

View File

@ -3934,6 +3934,10 @@ tarteaucitron.services.getquanty = {
return;
}
if (tarteaucitron.user.getquantyAlreadyLoaded !== undefined) {
return;
}
tarteaucitron.addScript('https://get.smart-data-systems.com/gq?site_id=' + tarteaucitron.user.getguanty + '&consent=1');
},
"fallback": function () {
@ -3942,6 +3946,8 @@ tarteaucitron.services.getquanty = {
return;
}
tarteaucitron.user.getquantyAlreadyLoaded = true;
tarteaucitron.addScript('https://get.smart-data-systems.com/gq?site_id=' + tarteaucitron.user.getguanty + '&notrack=1');
}
};