This commit is contained in:
Jori Lallo
2016-04-28 22:25:37 -07:00
parent 2f9233222d
commit cce82b3d43
79 changed files with 1495 additions and 496 deletions

13
server/api/user.js Normal file
View File

@ -0,0 +1,13 @@
import Router from 'koa-router';
import auth from './authentication';
import { presentUser } from '../presenters';
import { User } from '../models';
const router = new Router();
router.post('user.info', auth(), async (ctx) => {
ctx.body = { data: presentUser(ctx.state.user) };
});
export default router;