uses runNewTask where possible
added missing semicolons