1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-01-01 00:08:27 +01:00
unleash.unleash/lib/routes/admin-api/user.js
2018-01-16 14:26:32 +01:00

21 lines
383 B
JavaScript

'use strict';
const { Router } = require('express');
exports.router = function() {
const router = Router();
router.get('/', (req, res) => {
if (req.user) {
return res
.status(200)
.json(req.user)
.end();
} else {
return res.status(404).end();
}
});
return router;
};