added conditionals for DeadlineTasks and Periodic Tasks added to returnList