summaryrefslogtreecommitdiffstats
path: root/app/controllers/comments_controller.rb
diff options
context:
space:
mode:
authorJean-Philippe Lang <jp_lang@yahoo.fr>2012-12-11 17:51:30 +0000
committerJean-Philippe Lang <jp_lang@yahoo.fr>2012-12-11 17:51:30 +0000
commit0b9609468094fdb99ea9e0b68677dd178f85538c (patch)
tree736718d4e4684810e593863cfa051ac1a6a68251 /app/controllers/comments_controller.rb
parentcf66561b1ef5f80360588bc4e4691bf464cd88fc (diff)
downloadredmine-0b9609468094fdb99ea9e0b68677dd178f85538c.tar.gz
redmine-0b9609468094fdb99ea9e0b68677dd178f85538c.zip
Use named routes in controllers.
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@10981 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/controllers/comments_controller.rb')
-rw-r--r--app/controllers/comments_controller.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/app/controllers/comments_controller.rb b/app/controllers/comments_controller.rb
index ca9aa1a86..70b504381 100644
--- a/app/controllers/comments_controller.rb
+++ b/app/controllers/comments_controller.rb
@@ -32,12 +32,12 @@ class CommentsController < ApplicationController
flash[:notice] = l(:label_comment_added)
end
- redirect_to :controller => 'news', :action => 'show', :id => @news
+ redirect_to news_path(@news)
end
def destroy
@news.comments.find(params[:comment_id]).destroy
- redirect_to :controller => 'news', :action => 'show', :id => @news
+ redirect_to news_path(@news)
end
private