mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2026-07-10 11:21:36 +00:00
Fixing the rss incoming server side
This commit is contained in:
parent
4de5b92fa7
commit
7f5fde1de2
4 changed files with 8 additions and 8 deletions
|
|
@ -115,8 +115,8 @@ class PodcastController {
|
||||||
res.json({ podcast })
|
res.json({ podcast })
|
||||||
}
|
}
|
||||||
|
|
||||||
async getPodcastsWithInboundFeed(req, res) {
|
async getPodcastsWithIncomingFeeds(req, res) {
|
||||||
const podcasts = await Database.podcastModel.getAllInboundFeeds()
|
const podcasts = await Database.podcastModel.getAllIncomingFeeds()
|
||||||
res.json({
|
res.json({
|
||||||
podcasts
|
podcasts
|
||||||
})
|
})
|
||||||
|
|
|
||||||
|
|
@ -409,9 +409,9 @@ class PodcastManager {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
async getPodcastsWithInboundFeed() {
|
async getPodcastsWithIncomingFeeds() {
|
||||||
const podcasts = await Database.models.podcast.getAllInboundFeeds()
|
const podcasts = await Database.models.podcast.getAllIncomingFeeds()
|
||||||
Logger.info(`[PodcastManager] Fetched all podcasts with feed`)
|
Logger.info(`[PodcastManager] Fetched ${podcasts.length} podcasts with incoming feeds`)
|
||||||
return podcasts
|
return podcasts
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -120,9 +120,9 @@ class Podcast extends Model {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static async getAllInboundFeeds(){
|
static async getAllIncomingFeeds(){
|
||||||
const podcasts = await this.findAll()
|
const podcasts = await this.findAll()
|
||||||
return podcasts.map(p => this.getFromOld(p))
|
return podcasts.map(p => this.getFromOld({metadata: p.dataValues}))
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
|
|
@ -227,7 +227,7 @@ class ApiRouter {
|
||||||
//
|
//
|
||||||
this.router.post('/podcasts', PodcastController.create.bind(this))
|
this.router.post('/podcasts', PodcastController.create.bind(this))
|
||||||
this.router.post('/podcasts/feed', PodcastController.getPodcastFeed.bind(this))
|
this.router.post('/podcasts/feed', PodcastController.getPodcastFeed.bind(this))
|
||||||
this.router.get('/podcasts/inboundFeeds', PodcastController.getPodcastsWithInboundFeed.bind(this))
|
this.router.get('/podcasts/incomingFeeds', PodcastController.getPodcastsWithIncomingFeeds.bind(this))
|
||||||
this.router.get('/podcasts/:id/feed', PodcastController.middleware.bind(this), PodcastController.checkPodcastFeed.bind(this))
|
this.router.get('/podcasts/:id/feed', PodcastController.middleware.bind(this), PodcastController.checkPodcastFeed.bind(this))
|
||||||
this.router.post('/podcasts/opml', PodcastController.getFeedsFromOPMLText.bind(this))
|
this.router.post('/podcasts/opml', PodcastController.getFeedsFromOPMLText.bind(this))
|
||||||
this.router.get('/podcasts/:id/checknew', PodcastController.middleware.bind(this), PodcastController.checkNewEpisodes.bind(this))
|
this.router.get('/podcasts/:id/checknew', PodcastController.middleware.bind(this), PodcastController.checkNewEpisodes.bind(this))
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue