mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2025-06-26 10:49:00 +02:00
New data model update for Match tab
This commit is contained in:
parent
7d66f1eec9
commit
7348432594
3 changed files with 45 additions and 15 deletions
|
@ -49,12 +49,15 @@ class LibraryItemController {
|
|||
await this.db.updateLibraryItem(libraryItem)
|
||||
this.emitter('item_updated', libraryItem.toJSONExpanded())
|
||||
}
|
||||
res.json(libraryItem)
|
||||
res.json({
|
||||
updated: hasUpdates,
|
||||
libraryItem
|
||||
})
|
||||
}
|
||||
|
||||
// POST: api/items/:id/cover
|
||||
async uploadCover(req, res) {
|
||||
if (!req.user.canUpload || !req.user.canUpdate) {
|
||||
if (!req.user.canUpload) {
|
||||
Logger.warn('User attempted to upload a cover without permission', req.user)
|
||||
return res.sendStatus(403)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue