Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
get router() {
const router = Router();
router.use(inject('userSerializer'));
router.get('/', inject('getAllUsers'), this.index);
router.get('/:id', inject('getUser'), this.show);
router.post('/', inject('createUser'), this.create);
router.put('/:id', inject('updateUser'), this.update);
router.delete('/:id', inject('deleteUser'), this.delete);
return router;
},
get router() {
const router = Router();
router.use(inject('userSerializer'));
router.get('/', inject('getAllUsers'), this.index);
router.get('/:id', inject('getUser'), this.show);
router.post('/', inject('createUser'), this.create);
router.put('/:id', inject('updateUser'), this.update);
router.delete('/:id', inject('deleteUser'), this.delete);
return router;
},
get router() {
const router = Router();
router.use(inject('userSerializer'));
router.get('/', inject('getAllUsers'), this.index);
router.get('/:id', inject('getUser'), this.show);
router.post('/', inject('createUser'), this.create);
router.put('/:id', inject('updateUser'), this.update);
router.delete('/:id', inject('deleteUser'), this.delete);
return router;
},
get router() {
const router = Router();
router.use(inject('userSerializer'));
router.get('/', inject('getAllUsers'), this.index);
router.get('/:id', inject('getUser'), this.show);
router.post('/', inject('createUser'), this.create);
router.put('/:id', inject('updateUser'), this.update);
router.delete('/:id', inject('deleteUser'), this.delete);
return router;
},
get router() {
const router = Router();
router.use(inject('userSerializer'));
router.get('/', inject('getAllUsers'), this.index);
router.get('/:id', inject('getUser'), this.show);
router.post('/', inject('createUser'), this.create);
router.put('/:id', inject('updateUser'), this.update);
router.delete('/:id', inject('deleteUser'), this.delete);
return router;
},