mirror of
https://github.com/20kaushik02/spotify-manager.git
synced 2026-01-25 14:14:06 +00:00
some more fixes, URI stuff
This commit is contained in:
@@ -8,11 +8,11 @@ const typedefs = require("../typedefs");
|
||||
* @param {typedefs.Next} next
|
||||
*/
|
||||
const getPlaylistDetailsValidator = async (req, res, next) => {
|
||||
await query("playlist_id")
|
||||
await query("playlist_link")
|
||||
.notEmpty()
|
||||
.withMessage("playlist_id not defined in query")
|
||||
.isAlphanumeric()
|
||||
.withMessage("playlist_id must be alphanumeric (base-62)")
|
||||
.withMessage("playlist_link not defined in query")
|
||||
.isURL()
|
||||
.withMessage("playlist_link must be a valid link")
|
||||
.run(req);
|
||||
next();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user