Handle missing due_date in weekly tasks migration.

This commit is contained in:
Benjamin Meichsner 2013-09-02 15:42:03 +02:00
parent 5883bf50f3
commit bf1c2b5ed2

View file

@ -35,6 +35,8 @@ class MoveWeeklyTasks < ActiveRecord::Migration
private private
def weekly_task?(workgroup, task) def weekly_task?(workgroup, task)
return false if task.due_date.nil?
group_task = { group_task = {
weekday: workgroup.weekday, weekday: workgroup.weekday,
name: workgroup.task_name, name: workgroup.task_name,