diff options
Diffstat (limited to 'app/controllers')
-rw-r--r-- | app/controllers/admin_user_controller.rb | 2 | ||||
-rw-r--r-- | app/controllers/api_controller.rb | 2 | ||||
-rw-r--r-- | app/controllers/track_controller.rb | 4 | ||||
-rw-r--r-- | app/controllers/user_controller.rb | 16 |
4 files changed, 12 insertions, 12 deletions
diff --git a/app/controllers/admin_user_controller.rb b/app/controllers/admin_user_controller.rb index ed20ddcf4..52f7f330c 100644 --- a/app/controllers/admin_user_controller.rb +++ b/app/controllers/admin_user_controller.rb @@ -72,7 +72,7 @@ class AdminUserController < AdminController def login_as @admin_user = User.find(params[:id]) # check user does exist - post_redirect = PostRedirect.new( :uri => main_url(user_url(@admin_user)), :user_id => @admin_user.id, :circumstance => "login_as" ) + post_redirect = PostRedirect.new( :uri => main_url(user_path(@admin_user)), :user_id => @admin_user.id, :circumstance => "login_as" ) post_redirect.save! url = main_url(confirm_url(:email_token => post_redirect.email_token, :only_path => true)) diff --git a/app/controllers/api_controller.rb b/app/controllers/api_controller.rb index 15fb4f5f9..0d6582773 100644 --- a/app/controllers/api_controller.rb +++ b/app/controllers/api_controller.rb @@ -228,7 +228,7 @@ class ApiController < ApplicationController :user_name => request.user_name, } if request.user - this_event[:user_url] = main_url(user_url(request.user)) + this_event[:user_url] = main_url(user_path(request.user)) end @event_data.push(this_event) diff --git a/app/controllers/track_controller.rb b/app/controllers/track_controller.rb index 15da7f327..5b22f3795 100644 --- a/app/controllers/track_controller.rb +++ b/app/controllers/track_controller.rb @@ -74,7 +74,7 @@ class TrackController < ApplicationController return atom_feed_internal if params[:feed] == 'feed' if self.track_set - redirect_to user_url(@track_user) + redirect_to user_path(@track_user) end end @@ -188,7 +188,7 @@ class TrackController < ApplicationController # track_thing.created_at = Time.now() # as created_at is used to limit the alerts to start with # track_thing.save! # flash[:notice] = "You are now tracking " + track_thing.params[:list_description] + " by email daily" - # redirect_to user_url(track_thing.tracking_user) + # redirect_to user_path(track_thing.tracking_user) else raise "new medium not handled " + new_medium end diff --git a/app/controllers/user_controller.rb b/app/controllers/user_controller.rb index 4ee527bae..f0e3cd0d3 100644 --- a/app/controllers/user_controller.rb +++ b/app/controllers/user_controller.rb @@ -313,7 +313,7 @@ class UserController < ApplicationController post_redirect = PostRedirect.find_by_token(params[:pretoken]) do_post_redirect post_redirect else - redirect_to user_url(@user) + redirect_to user_path(@user) end end else @@ -388,7 +388,7 @@ class UserController < ApplicationController # Now clear the circumstance session[:user_circumstance] = nil flash[:notice] = _("You have now changed your email address used on {{site_name}}",:site_name=>site_name) - redirect_to user_url(@user) + redirect_to user_path(@user) end # Send a message to another user @@ -422,12 +422,12 @@ class UserController < ApplicationController ContactMailer.deliver_user_message( @user, @recipient_user, - main_url(user_url(@user)), + main_url(user_path(@user)), params[:contact][:subject], params[:contact][:message] ) flash[:notice] = _("Your message to {{recipient_user_name}} has been sent!",:recipient_user_name=>CGI.escapeHTML(@recipient_user.name)) - redirect_to user_url(@recipient_user) + redirect_to user_path(@recipient_user) return end else @@ -476,7 +476,7 @@ class UserController < ApplicationController @user.set_profile_photo(@profile_photo) @draft_profile_photo.destroy flash[:notice] = _("Thank you for updating your profile photo") - redirect_to user_url(@user) + redirect_to user_path(@user) return end @@ -492,7 +492,7 @@ class UserController < ApplicationController if !@user.get_about_me_for_html_display.empty? flash[:notice] = _("Thank you for updating your profile photo") - redirect_to user_url(@user) + redirect_to user_path(@user) else flash[:notice] = _("<p>Thanks for updating your profile photo.</p> <p><strong>Next...</strong> You can put some text about you and your research on your profile.</p>") @@ -520,7 +520,7 @@ class UserController < ApplicationController end flash[:notice] = _("You've now cleared your profile photo") - redirect_to user_url(@user) + redirect_to user_path(@user) end # before they've cropped it @@ -571,7 +571,7 @@ class UserController < ApplicationController @user.save! if @user.profile_photo flash[:notice] = _("You have now changed the text about you on your profile.") - redirect_to user_url(@user) + redirect_to user_path(@user) else flash[:notice] = _("<p>Thanks for changing the text about you on your profile.</p> <p><strong>Next...</strong> You can upload a profile photograph too.</p>") |