Merge pull request #200 from real34/patch-1

Add support for analytics pre-pageview userland logic
This commit is contained in:
Amauri CHAMPEAUX 2018-08-28 10:45:31 +02:00 committed by GitHub
commit 3979039ece
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 0 deletions

View File

@ -1064,6 +1064,10 @@ tarteaucitron.services.analytics = {
ga('set', 'anonymizeIp', true);
}
if (typeof tarteaucitron.user.analyticsPrepare === 'function') {
tarteaucitron.user.analyticsPrepare();
}
if (tarteaucitron.user.analyticsPageView) {
ga('send', 'pageview', tarteaucitron.user.analyticsPageView);
} else {