mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2026-11-20 07:31:34 +01:00
Update Playlist model & controller to remove usage of old Playlist object, remove old Playlist
This commit is contained in:
1 parent
6780ef9b37
commit
9785bc02ea
7 files changed
+501
-513
No files matched your search
@@ -35,6 +35,9 @@ class CollectionController {
|
||||
if (!reqBody.name || !reqBody.libraryId) {
|
||||
return res.status(400).send('Invalid collection data')
|
||||
}
|
||||
if (reqBody.description && typeof reqBody.description !== 'string') {
|
||||
return res.status(400).send('Invalid collection description')
|
||||
}
|
||||
const libraryItemIds = (reqBody.books || []).filter((b) => !!b && typeof b == 'string')
|
||||
if (!libraryItemIds.length) {
|
||||
return res.status(400).send('Invalid collection data. No books')
|
||||
|
||||
Reference in new issue
Block a user