google analytics refactorying