From: Jean-Philippe Lang Date: Wed, 4 Jul 2012 17:34:37 +0000 (+0000) Subject: Perf: don't load parent message for generating a link. X-Git-Tag: 2.1.0~399 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=df412551058c0ca442346e4671ef2ae4c6a9a857;p=redmine.git Perf: don't load parent message for generating a link. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9904 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index 7772035d3..eaf89da8a 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -128,7 +128,7 @@ module ApplicationHelper h(truncate(message.subject, :length => 60)), { :controller => 'messages', :action => 'show', :board_id => message.board_id, - :id => message.root, + :id => (message.parent_id || message.id), :r => (message.parent_id && message.id), :anchor => (message.parent_id ? "message-#{message.id}" : nil) }.merge(options),