Method removeTask()