Fix:Global search support podcasts

This commit is contained in:
advplyr 2022-04-12 16:54:52 -05:00
parent 10d9e11387
commit 469278cd1e
7 changed files with 42 additions and 17 deletions

View file

@ -40,6 +40,12 @@ export default {
media() {
return this.libraryItem ? this.libraryItem.media || {} : {}
},
mediaType() {
return this.libraryItem ? this.libraryItem.mediaType : null
},
isPodcast() {
return this.mediaType == 'podcast'
},
mediaMetadata() {
return this.media.metadata || {}
},
@ -49,11 +55,9 @@ export default {
subtitle() {
return this.mediaMetadata.subtitle || ''
},
authors() {
return this.mediaMetadata.authors || []
},
authorName() {
return this.authors.map((au) => au.name).join(', ')
if (this.isPodcast) return this.mediaMetadata.author || 'Unknown'
return this.mediaMetadata.authorName || 'Unknown'
},
matchHtml() {
if (!this.matchText || !this.search) return ''