Skip to content
Snippets Groups Projects
user.js 522 B
Newer Older
  • Learn to ignore specific revisions
  • Bastien's avatar
    Bastien committed
    const express = require('express');
    const router = express.Router();
    const controller = require('../controllers/userController');
    const auth = require('../middlewares/auth');
    
    
    Bastien's avatar
    Bastien committed
    router.get('/',auth.auth,controller.getUserInformations);
    
    Bastien's avatar
    Bastien committed
    
    router.post('/login',controller.login);
    
    router.post('/signup', controller.signup);
    
    
    router.get('/logout',auth.auth,controller.logout);
    
    Bastien's avatar
    Bastien committed
    
    
    Bastien's avatar
    Bastien committed
    router.get('/seenMovies',auth.auth,controller.getUserSeenMovies);
    
    
    Bastien's avatar
    Bastien committed
    // router.put('/',auth.auth,controller.changeUserInfos);
    
    Bastien's avatar
    Bastien committed
    
    
    Bastien's avatar
    Bastien committed
    
    module.exports = router;