From 8b1d10fab257d8a0ce7230f27a530dd7f8140acc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?U=C4=A3is=20Ozols?= Date: Wed, 27 Jun 2012 22:29:31 +0300 Subject: Use shorter syntax of render where possible. --- app/controllers/refinery/blog/admin/comments_controller.rb | 6 +++--- app/controllers/refinery/blog/admin/posts_controller.rb | 2 +- app/controllers/refinery/blog/posts_controller.rb | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) (limited to 'app/controllers/refinery') diff --git a/app/controllers/refinery/blog/admin/comments_controller.rb b/app/controllers/refinery/blog/admin/comments_controller.rb index 8565b28..18246ee 100644 --- a/app/controllers/refinery/blog/admin/comments_controller.rb +++ b/app/controllers/refinery/blog/admin/comments_controller.rb @@ -12,14 +12,14 @@ module Refinery def index @comments = Refinery::Blog::Comment.unmoderated.page(params[:page]) - render :action => 'index' + render :index end def approved unless params[:id].present? @comments = Refinery::Blog::Comment.approved.page(params[:page]) - render :action => 'index' + render :index else @comment = Refinery::Blog::Comment.find(params[:id]) @comment.approve! @@ -33,7 +33,7 @@ module Refinery unless params[:id].present? @comments = Refinery::Blog::Comment.rejected.page(params[:page]) - render :action => 'index' + render :index else @comment = Refinery::Blog::Comment.find(params[:id]) @comment.reject! diff --git a/app/controllers/refinery/blog/admin/posts_controller.rb b/app/controllers/refinery/blog/admin/posts_controller.rb index e48c00d..cbde2f8 100644 --- a/app/controllers/refinery/blog/admin/posts_controller.rb +++ b/app/controllers/refinery/blog/admin/posts_controller.rb @@ -66,7 +66,7 @@ module Refinery end else unless request.xhr? - render :action => 'new' + render :new else render :partial => "/refinery/admin/error_messages", :locals => { diff --git a/app/controllers/refinery/blog/posts_controller.rb b/app/controllers/refinery/blog/posts_controller.rb index bb242fd..bd579c4 100644 --- a/app/controllers/refinery/blog/posts_controller.rb +++ b/app/controllers/refinery/blog/posts_controller.rb @@ -51,7 +51,7 @@ module Refinery :anchor => "comment-#{@comment.to_param}") end else - render :action => 'show' + render :show end end -- cgit v1.2.3