diff --git a/db/migrate/20161122152339_new_plan_template_structure.rb b/db/migrate/20161122152339_new_plan_template_structure.rb index 02f4f05..fc52a53 100644 --- a/db/migrate/20161122152339_new_plan_template_structure.rb +++ b/db/migrate/20161122152339_new_plan_template_structure.rb @@ -185,7 +185,7 @@ template = initTemplate(dmptemplate) # needs to select next version of temp based on old_temp_id # some differences between a customised and un-customised template # customised templates need a different organisation_id - template.organisation_id = project.organisation_id + template.organisation_id = project.organisation_id unless project.organisation_id.nil? # updated to not overwrite with nil # customised templates follow different version rules template.save! # since template was not a match, need to gen/copy all data below the template level @@ -431,4 +431,4 @@ role.user_id = project_group.user_id role.new_plan_id = new_plan.id return role -end \ No newline at end of file +end