Add condition to populate task.