mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2025-08-03 09:44:41 +02:00
Fix API including basepath in tracks contentUrl
This commit is contained in:
parent
a58d486c44
commit
aebb3ff413
6 changed files with 16 additions and 12 deletions
|
@ -29,7 +29,7 @@ class AudioTrack {
|
|||
this.duration = audioFile.duration
|
||||
this.title = audioFile.metadata.filename || ''
|
||||
|
||||
this.contentUrl = `${global.RouterBasePath}/api/items/${itemId}/file/${audioFile.ino}`
|
||||
this.contentUrl = `/api/items/${itemId}/file/${audioFile.ino}`
|
||||
this.mimeType = audioFile.mimeType
|
||||
this.codec = audioFile.codec || null
|
||||
this.metadata = audioFile.metadata.clone()
|
||||
|
@ -44,4 +44,4 @@ class AudioTrack {
|
|||
this.mimeType = 'application/vnd.apple.mpegurl'
|
||||
}
|
||||
}
|
||||
module.exports = AudioTrack
|
||||
module.exports = AudioTrack
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue