old_contents: 'use strict';
  angular
    .module('freelook.info')
    .factory('analytics', function ($window, $rootScope, $location) {
  
      function init() {
        $rootScope.$on('$routeChangeSuccess', function () {
          if ($window.ga) {
            $window.ga('send', 'pageview', {page: $location.path()});
          }
        });
      }
  
      return {
        init: init
      };
  
    });
  
  
  
new_contents: 'use strict';
  angular
    .module('freelook.info')
    .factory('analytics', function ($window, $rootScope, $location) {
  
      function init() {
        $rootScope.$on('$routeChangeSuccess', function () {
          if ($window.ga) {
            $window.ga('send', 'pageview', {page: decodeURIComponent($location.url())});
          }
        });
      }
  
      return {
        init: init
      };
  
    });
  
  
  
subject: improve analytics