summaryrefslogtreecommitdiffstats
path: root/lib/redmine/helpers
diff options
context:
space:
mode:
authorGo MAEDA <maeda@farend.jp>2018-08-02 21:54:21 +0000
committerGo MAEDA <maeda@farend.jp>2018-08-02 21:54:21 +0000
commiteee1c36b4b7f0cee23ebc5d3848fa2b606f603c8 (patch)
tree6618b8113ac99e4feb65ffbab90f87bc5da10349 /lib/redmine/helpers
parentc76a021e92e77036152935ac19af10893f56669f (diff)
downloadredmine-eee1c36b4b7f0cee23ebc5d3848fa2b606f603c8.tar.gz
redmine-eee1c36b4b7f0cee23ebc5d3848fa2b606f603c8.zip
Replace Enumerable#sort with faster Enumerable#sort_by (#29299).
Patch by Go MAEDA. git-svn-id: http://svn.redmine.org/redmine/trunk@17462 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'lib/redmine/helpers')
-rw-r--r--lib/redmine/helpers/gantt.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/redmine/helpers/gantt.rb b/lib/redmine/helpers/gantt.rb
index ca3b70b6f..312a3133a 100644
--- a/lib/redmine/helpers/gantt.rb
+++ b/lib/redmine/helpers/gantt.rb
@@ -619,7 +619,7 @@ module Redmine
end
def self.sort_issues!(issues)
- issues.sort! {|a, b| sort_issue_logic(a) <=> sort_issue_logic(b)}
+ issues.sort_by! {|issue| sort_issue_logic(issue)}
end
def self.sort_issue_logic(issue)