Fixing bug in task runner
async js now gets number of running tasks