Update to suit new style of running tasks.