From 4ed1228d55aa33bc2b3c399fc592b6887e22df5e Mon Sep 17 00:00:00 2001 From: =?utf8?q?Bj=C3=B8rn=20Erik=20Pedersen?= Date: Fri, 25 May 2018 16:05:45 +0200 Subject: [PATCH] Fix GA anonymizeIp order --- tpl/tplimpl/embedded/templates.autogen.go | 4 ++-- tpl/tplimpl/embedded/templates/google_analytics.html | 2 +- tpl/tplimpl/embedded/templates/google_analytics_async.html | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tpl/tplimpl/embedded/templates.autogen.go b/tpl/tplimpl/embedded/templates.autogen.go index db35f789..41e33143 100644 --- a/tpl/tplimpl/embedded/templates.autogen.go +++ b/tpl/tplimpl/embedded/templates.autogen.go @@ -123,8 +123,8 @@ if (!doNotTrack) { {{ else }} ga('create', '{{ . }}', 'auto'); {{ end -}} + {{ if $pc.AnonymizeIP }}ga('set', 'anonymizeIp', true);{{ end }} ga('send', 'pageview'); - {{ if $pc.AnonymizeIP }}ga('set', 'anonymizeIp', true);{{ end -}} } {{ end }} @@ -159,8 +159,8 @@ if (!doNotTrack) { {{ else }} ga('create', '{{ . }}', 'auto'); {{ end -}} + {{ if $pc.AnonymizeIP }}ga('set', 'anonymizeIp', true);{{ end }} ga('send', 'pageview'); - {{ if $pc.AnonymizeIP }}ga('set', 'anonymizeIp', true);{{ end -}} } diff --git a/tpl/tplimpl/embedded/templates/google_analytics.html b/tpl/tplimpl/embedded/templates/google_analytics.html index 429672a7..08b60f45 100755 --- a/tpl/tplimpl/embedded/templates/google_analytics.html +++ b/tpl/tplimpl/embedded/templates/google_analytics.html @@ -22,8 +22,8 @@ if (!doNotTrack) { {{ else }} ga('create', '{{ . }}', 'auto'); {{ end -}} + {{ if $pc.AnonymizeIP }}ga('set', 'anonymizeIp', true);{{ end }} ga('send', 'pageview'); - {{ if $pc.AnonymizeIP }}ga('set', 'anonymizeIp', true);{{ end -}} } {{ end }} diff --git a/tpl/tplimpl/embedded/templates/google_analytics_async.html b/tpl/tplimpl/embedded/templates/google_analytics_async.html index 8fb746e0..6a88ed85 100755 --- a/tpl/tplimpl/embedded/templates/google_analytics_async.html +++ b/tpl/tplimpl/embedded/templates/google_analytics_async.html @@ -19,8 +19,8 @@ if (!doNotTrack) { {{ else }} ga('create', '{{ . }}', 'auto'); {{ end -}} + {{ if $pc.AnonymizeIP }}ga('set', 'anonymizeIp', true);{{ end }} ga('send', 'pageview'); - {{ if $pc.AnonymizeIP }}ga('set', 'anonymizeIp', true);{{ end -}} } -- 2.30.2