mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2025-07-24 12:54:31 +02:00
Update:Trim whitespace from audio file meta tag values #1305
This commit is contained in:
parent
c4be75b5bd
commit
657d4dd705
2 changed files with 14 additions and 9 deletions
|
@ -88,8 +88,8 @@ class PodcastMetadata {
|
|||
}
|
||||
|
||||
searchQuery(query) { // Returns key if match is found
|
||||
var keysToCheck = ['title', 'author', 'itunesId', 'itunesArtistId']
|
||||
for (var key of keysToCheck) {
|
||||
const keysToCheck = ['title', 'author', 'itunesId', 'itunesArtistId']
|
||||
for (const key of keysToCheck) {
|
||||
if (this[key] && cleanStringForSearch(String(this[key])).includes(query)) {
|
||||
return {
|
||||
matchKey: key,
|
||||
|
@ -118,8 +118,8 @@ class PodcastMetadata {
|
|||
}
|
||||
|
||||
update(payload) {
|
||||
var json = this.toJSON()
|
||||
var hasUpdates = false
|
||||
const json = this.toJSON()
|
||||
let hasUpdates = false
|
||||
for (const key in json) {
|
||||
if (payload[key] !== undefined) {
|
||||
if (!areEquivalent(payload[key], json[key])) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue