From cb490caff4d0222818c7fb18efb8511443d70197 Mon Sep 17 00:00:00 2001 From: Eric Davis Date: Sat, 19 Feb 2011 20:58:12 -0800 Subject: [PATCH] [#190] Work around a nil error introduced in c1cced5139e7 --- lib/redmine/helpers/gantt.rb | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/lib/redmine/helpers/gantt.rb b/lib/redmine/helpers/gantt.rb index b0d72290..b68534b2 100644 --- a/lib/redmine/helpers/gantt.rb +++ b/lib/redmine/helpers/gantt.rb @@ -110,8 +110,12 @@ module Redmine total += number_of_rows_on_project(project) end end - - rows > @max_rows ? @max_rows : rows + + if @max_rows.present? + rows > @max_rows ? @max_rows : rows + else + rows + end end # Returns the number of rows that will be used to list a project on