mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2025-08-02 01:05:25 +02:00
Update:Changing author name to match another authors name will merge the authors #487
This commit is contained in:
parent
217bbb4a8e
commit
6cbfd8679b
3 changed files with 61 additions and 22 deletions
|
@ -191,6 +191,14 @@ class BookMetadata {
|
|||
return true
|
||||
}
|
||||
|
||||
replaceAuthor(oldAuthor, newAuthor) {
|
||||
this.authors = this.authors.filter(au => au.id !== oldAuthor.id) // Remove old author
|
||||
this.authors.push({
|
||||
id: newAuthor.id,
|
||||
name: newAuthor.name
|
||||
})
|
||||
}
|
||||
|
||||
setData(scanMediaData = {}) {
|
||||
this.title = scanMediaData.title || null
|
||||
this.subtitle = scanMediaData.subtitle || null
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue