Refactored the BaseTask into ComponentTask.