From 8a356baf3e320607ec6f85dd33f7fa8887dc1ebd Mon Sep 17 00:00:00 2001 From: Jean-Philippe Lang Date: Sun, 21 Sep 2008 12:45:22 +0000 Subject: Unescape back_url param before calling redirect_to. git-svn-id: http://redmine.rubyforge.org/svn/trunk@1893 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- app/controllers/timelog_controller.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'app/controllers/timelog_controller.rb') diff --git a/app/controllers/timelog_controller.rb b/app/controllers/timelog_controller.rb index 897a50fe5..c333c02bb 100644 --- a/app/controllers/timelog_controller.rb +++ b/app/controllers/timelog_controller.rb @@ -194,7 +194,7 @@ class TimelogController < ApplicationController @time_entry.attributes = params[:time_entry] if request.post? and @time_entry.save flash[:notice] = l(:notice_successful_update) - redirect_to(params[:back_url].blank? ? {:action => 'details', :project_id => @time_entry.project} : params[:back_url]) + redirect_back_or_default :action => 'details', :project_id => @time_entry.project return end end -- cgit v1.2.3