Created
June 27, 2011 12:22
-
-
Save kristianhellquist/1048762 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
commit 71add8105fd6802ff4198096aa35a3d06bab09fb | |
Author: Tomasz Warkocki <warkocz@codequest.eu> | |
Date: Wed Dec 1 13:55:24 2010 +0100 | |
changed mnduser google analytics value from md5 to id | |
diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb | |
index 529e479..bd47d6b 100644 | |
--- a/app/helpers/application_helper.rb | |
+++ b/app/helpers/application_helper.rb | |
@@ -65,13 +65,13 @@ module ApplicationHelper | |
goal_tracking = [] | |
if @user | |
- custom_tracking << "_gaq.push(['_setCustomVar', 2, 'mnduser', '#{@user.analytics_id}', 1]);" | |
+ custom_tracking << "_gaq.push(['_setCustomVar', 2, 'mnduser', '#{@user.id}', 1]);" | |
custom_tracking << "_gaq.push(['_setCustomVar', 3, 'mndtype', '#{@user.class.to_s}', 1]);" | |
custom_tracking << "_gaq.push(['_setCustomVar', 4, 'mndloggedin', 1, 3]);" | |
end | |
if defined?(@item) && (params[:controller] == "pressroom" || params[:controller] == "view") | |
- custom_tracking << "_gaq.push(['_setCustomVar', 5, 'mdnitem', '#{@item.class.to_s.downcase}_#{@item.id}', 3]);" | |
+ custom_tracking << "_gaq.push(['_setCustomVar', 5, 'mnditem', '#{@item.class.to_s.downcase}_#{@item.id}', 3]);" | |
end | |
unless session[:analytics].blank? | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment