modified to add Task.deadline