mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2025-08-04 18:24:46 +02:00
Update collection API routes to load libraryItems from DB
This commit is contained in:
parent
38029d1202
commit
db80cec168
8 changed files with 344 additions and 139 deletions
|
@ -12,7 +12,7 @@ class RssFeedManager {
|
|||
|
||||
async validateFeedEntity(feedObj) {
|
||||
if (feedObj.entityType === 'collection') {
|
||||
const collection = await Database.models.collection.getById(feedObj.entityId)
|
||||
const collection = await Database.models.collection.getOldById(feedObj.entityId)
|
||||
if (!collection) {
|
||||
Logger.error(`[RssFeedManager] Removing feed "${feedObj.id}". Collection "${feedObj.entityId}" not found`)
|
||||
return false
|
||||
|
@ -102,7 +102,7 @@ class RssFeedManager {
|
|||
await Database.updateFeed(feed)
|
||||
}
|
||||
} else if (feed.entityType === 'collection') {
|
||||
const collection = await Database.models.collection.getById(feed.entityId)
|
||||
const collection = await Database.models.collection.getOldById(feed.entityId)
|
||||
if (collection) {
|
||||
const collectionExpanded = collection.toJSONExpanded(Database.libraryItems)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue