session[:fingerprint] = user.fingerprint
session_expires_after 28.days if session[:remember_me]
+ cookies.delete :_osm_anonymous_notes_count
+
target = referer || url_for(:controller => :site, :action => :index)
# The user is logged in, so decide where to send them:
# - If they were referred to the login, send them back there.
# - Otherwise, send them to the home page.
if !user.terms_seen
- redirect_to :controller => :users, :action => :terms, :referer => target
+ redirect_to account_terms_path(:referer => target)
elsif user.blocked_on_view
redirect_to user.blocked_on_view, :referer => target
else