1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | 1x 1x 1x 1x 1x 1x 1x | const express = require('express'); const auth = require('../utils/auth'); const controller = require('./users.api'); const policy = require('./users.policy'); const router = express.Router(); // GET /api/me router.get('/', auth.authenticate(), controller.fetchMe, auth.authorize(policy.canRetrieve, { authenticate: false }), controller.retrieve); module.exports = router; |