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