Update taskService.js

some important changes