From 18270ee5879b387a23f659339555269319eb861f Mon Sep 17 00:00:00 2001 From: Jean-Philippe Lang Date: Fri, 6 Apr 2012 16:51:10 +0000 Subject: Code cleanup. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9363 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- app/controllers/attachments_controller.rb | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'app/controllers/attachments_controller.rb') diff --git a/app/controllers/attachments_controller.rb b/app/controllers/attachments_controller.rb index 967032d92..425bfab94 100644 --- a/app/controllers/attachments_controller.rb +++ b/app/controllers/attachments_controller.rb @@ -88,9 +88,7 @@ class AttachmentsController < ApplicationController end # Make sure association callbacks are called @attachment.container.attachments.delete(@attachment) - redirect_to :back - rescue ::ActionController::RedirectBackError - redirect_to :controller => 'projects', :action => 'show', :id => @project + redirect_back_or_default project_path(@project) end private -- cgit v1.2.3