Browse files

Prevent error when Mantis version.date_order is nil (#7476).

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@4765 e93f8b46-1217-0410-a6f0-8f06a7374b81
  • Loading branch information...
1 parent e6bf7ea commit a8473368ee209f720bbaf7b84714a615b2be7db1 @jplang jplang committed with Jan 28, 2011
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/tasks/migrate_from_mantis.rake
View
2 lib/tasks/migrate_from_mantis.rake
@@ -287,7 +287,7 @@ task :migrate_from_mantis => :environment do
project.versions.each do |version|
v = Version.new :name => encode(version.version),
:description => encode(version.description),
- :effective_date => version.date_order.to_date
+ :effective_date => (version.date_order ? version.date_order.to_date : nil)
v.project = p
v.save
versions_map[version.id] = v.id

0 comments on commit a847336

Please sign in to comment.