Rails4: replace deprecated passing options to find at MessagesController

git-svn-id: http://svn.redmine.org/redmine/trunk@12520 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Toshi MARUYAMA 2014-01-08 06:11:46 +00:00
parent c92f425309
commit 273e7420d4
1 changed files with 2 additions and 2 deletions

View File

@ -126,14 +126,14 @@ class MessagesController < ApplicationController
private
def find_message
return unless find_board
@message = @board.messages.find(params[:id], :include => :parent)
@message = @board.messages.includes(:parent).find(params[:id])
@topic = @message.root
rescue ActiveRecord::RecordNotFound
render_404
end
def find_board
@board = Board.find(params[:board_id], :include => :project)
@board = Board.includes(:project).find(params[:board_id])
@project = @board.project
rescue ActiveRecord::RecordNotFound
render_404