Fixed TaskBuilder to use the specified Task class