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
This commit is contained in:
Jean-Philippe Lang 2011-01-28 19:45:09 +00:00
parent 898a8c885b
commit d39e12c202
1 changed files with 1 additions and 1 deletions

View File

@ -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