mirror of
https://github.com/20kaushik02/spotify-manager.git
synced 2025-12-06 13:44:06 +00:00
bit of validation, some fixes, some auth corrections scrapped graph db stuff some misc. stuff, check the diff if you want bruh
23 lines
543 B
JavaScript
23 lines
543 B
JavaScript
const router = require('express').Router();
|
|
|
|
const { getUserPlaylists, getPlaylistDetails, } = require('../controllers/playlists');
|
|
const { isAuthenticated } = require('../middleware/authCheck');
|
|
const { getPlaylistDetailsValidator } = require('../validators/playlists');
|
|
const validator = require("../validators");
|
|
|
|
router.get(
|
|
"/user",
|
|
isAuthenticated,
|
|
validator.validate,
|
|
getUserPlaylists
|
|
);
|
|
router.get(
|
|
"/details",
|
|
isAuthenticated,
|
|
getPlaylistDetailsValidator,
|
|
validator.validate,
|
|
getPlaylistDetails
|
|
);
|
|
|
|
module.exports = router;
|