mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2025-06-23 01:09:26 +02:00
Update:Remove manual sorting of podcast episodes and default to sort by published at
This commit is contained in:
parent
3c465994fe
commit
3e98b6f749
7 changed files with 23 additions and 136 deletions
|
@ -224,20 +224,6 @@ class LibraryItemController {
|
|||
res.json(libraryItem.toJSON())
|
||||
}
|
||||
|
||||
// PATCH: api/items/:id/episodes
|
||||
async updateEpisodes(req, res) { // For updating podcast episode order
|
||||
var libraryItem = req.libraryItem
|
||||
var orderedFileData = req.body.episodes
|
||||
if (!libraryItem.media.setEpisodeOrder) {
|
||||
Logger.error(`[LibraryItemController] updateEpisodes invalid media type ${libraryItem.id}`)
|
||||
return res.sendStatus(500)
|
||||
}
|
||||
libraryItem.media.setEpisodeOrder(orderedFileData)
|
||||
await this.db.updateLibraryItem(libraryItem)
|
||||
this.emitter('item_updated', libraryItem.toJSONExpanded())
|
||||
res.json(libraryItem.toJSON())
|
||||
}
|
||||
|
||||
// DELETE: api/items/:id/episode/:episodeId
|
||||
async removeEpisode(req, res) {
|
||||
var episodeId = req.params.episodeId
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue