mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2025-06-22 08:53:41 +02:00
Add:Option to disable backup of audio files in embed metadata tool #1370
This commit is contained in:
parent
7ccf36a896
commit
5a26704c32
5 changed files with 68 additions and 252 deletions
|
@ -47,7 +47,6 @@ class ToolsController {
|
|||
res.sendStatus(200)
|
||||
}
|
||||
|
||||
|
||||
// POST: api/tools/item/:id/embed-metadata
|
||||
async embedAudioFileMetadata(req, res) {
|
||||
if (!req.user.isAdminOrUp) {
|
||||
|
@ -60,9 +59,11 @@ class ToolsController {
|
|||
return res.sendStatus(500)
|
||||
}
|
||||
|
||||
const useTone = req.query.tone === '1'
|
||||
const forceEmbedChapters = req.query.forceEmbedChapters === '1'
|
||||
this.audioMetadataManager.updateMetadataForItem(req.user, req.libraryItem, useTone, forceEmbedChapters)
|
||||
const options = {
|
||||
forceEmbedChapters: req.query.forceEmbedChapters === '1',
|
||||
backup: req.query.backup === '1'
|
||||
}
|
||||
this.audioMetadataManager.updateMetadataForItem(req.user, req.libraryItem, options)
|
||||
res.sendStatus(200)
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue