2016-05-13 20:49:56 +00:00
|
|
|
import { Router } from 'express';
|
|
|
|
import * as SessionController from '../controllers/session.controller';
|
2016-05-13 20:49:56 +00:00
|
|
|
|
2016-05-13 20:49:56 +00:00
|
|
|
const router = new Router();
|
|
|
|
|
2018-01-09 20:57:49 +00:00
|
|
|
router.post('/login', SessionController.createSession);
|
2016-05-17 19:50:37 +00:00
|
|
|
|
2018-01-09 20:57:49 +00:00
|
|
|
router.get('/session', SessionController.getSession);
|
2016-06-14 23:11:42 +00:00
|
|
|
|
2018-01-09 20:57:49 +00:00
|
|
|
router.get('/logout', SessionController.destroySession);
|
2016-08-28 00:46:20 +00:00
|
|
|
|
2016-06-14 20:48:16 +00:00
|
|
|
export default router;
|