mycontroller-org / mycontroller-v1-legacy

The Open Source Controller
http://www.MyController.org
Apache License 2.0
148 stars 90 forks source link

Google Analytics disable still tries to load analytics #496

Open githubcdr opened 5 years ago

githubcdr commented 5 years ago

Hi,

I noticed that I receive timeouts when reloading a page at random, after inspecting this issue I found that this code is still present and active even when disabling Google Analytics in the properties file;

 <script>
      (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
      (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
      m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
      })(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
    </script>

Since I block Google analytics in DNS this seems to cause a long page load (5+ seconds), please note that I'm not 100% sure but previous versions did not have this issue.

jkandasa commented 5 years ago

@githubcdr can you clear cache on your browser and try again?

githubcdr commented 5 years ago

Hi, I tried but this does not seem to resolv the issue, it might be related to the load on my docker host, I'll have to investigate.