Updated service.js