From 21ca0e3d0a87f688a641466f27cccc79c64e4d6d Mon Sep 17 00:00:00 2001 From: Go MAEDA Date: Mon, 2 Jan 2023 06:10:53 +0000 Subject: Fix RuboCop offense Style/MinMaxComparison (#36919). git-svn-id: https://svn.redmine.org/redmine/trunk@22019 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- lib/redmine/helpers/gantt.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/redmine/helpers') diff --git a/lib/redmine/helpers/gantt.rb b/lib/redmine/helpers/gantt.rb index ade37a33e..448d3190e 100644 --- a/lib/redmine/helpers/gantt.rb +++ b/lib/redmine/helpers/gantt.rb @@ -117,7 +117,7 @@ module Redmine return @number_of_rows if @number_of_rows rows = projects.inject(0) {|total, p| total += number_of_rows_on_project(p)} - rows > @max_rows ? @max_rows : rows + [rows, @max_rows].min end # Returns the number of rows that will be used to list a project on -- cgit v1.2.3