From 251b1f75e9407d28ef8e952266a9299293a9f040 Mon Sep 17 00:00:00 2001 From: Jean-Philippe Lang Date: Fri, 2 May 2008 16:48:09 +0000 Subject: [PATCH] Fixed: error on Trac import when :due attribute is nil (#1164). git-svn-id: http://redmine.rubyforge.org/svn/trunk@1406 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- lib/tasks/migrate_from_trac.rake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/tasks/migrate_from_trac.rake b/lib/tasks/migrate_from_trac.rake index 7fe1f09ac..48a774eef 100644 --- a/lib/tasks/migrate_from_trac.rake +++ b/lib/tasks/migrate_from_trac.rake @@ -92,7 +92,7 @@ namespace :redmine do set_table_name :milestone def due - if read_attribute(:due) > 0 + if read_attribute(:due) && read_attribute(:due) > 0 Time.at(read_attribute(:due)).to_date else nil