diff options
-rw-r--r-- | templates/web/fixmystreet.com/header_extra.html | 2 | ||||
-rw-r--r-- | web/cobrands/fixmystreet.com/js.js | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/templates/web/fixmystreet.com/header_extra.html b/templates/web/fixmystreet.com/header_extra.html index 64a8ee44a..b55abc957 100644 --- a/templates/web/fixmystreet.com/header_extra.html +++ b/templates/web/fixmystreet.com/header_extra.html @@ -2,7 +2,7 @@ <link rel="Shortcut Icon" type="image/x-icon" href="/cobrands/fixmystreet.com/favicon.ico"> [%# We are conducting an A/B experiment %] -[% IF c.config.BASE_URL == "https://www.fixmystreet.com" AND not admin %] +[% IF c.config.BASE_URL == "https://www.fixmystreet.com" AND not admin AND NOT c.req.header('User-Agent').match('Google Page Speed') %] <script src="//www.google-analytics.com/cx/api.js?experiment=ZwMlZkAhSbK_tP_QG64QrQ"></script> <script nonce="[% csp_nonce %]"> var variation = cxApi.chooseVariation(), diff --git a/web/cobrands/fixmystreet.com/js.js b/web/cobrands/fixmystreet.com/js.js index 9dbd11f2c..c54c543de 100644 --- a/web/cobrands/fixmystreet.com/js.js +++ b/web/cobrands/fixmystreet.com/js.js @@ -11,7 +11,7 @@ $(function(){ $.cookie('has_seen_country_message', 1, {expires: 365, path: '/'}); }); - if ( $('body.frontpage').length ) { + if ( $('body.frontpage').length && -1 == navigator.userAgent.indexOf('Google Page Speed')) { if (!$.cookie('has_seen_country_message')) { $.ajax({ url: 'https://gaze.mysociety.org/gaze-rest?f=get_country_from_ip', |