feat: transcoding info in responses, to enable Jamstash to play transcoded FLAC. hardcoded for now
This commit is contained in:
@@ -2,6 +2,7 @@ package subsonic
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"mime"
|
||||||
"net/http"
|
"net/http"
|
||||||
"strconv"
|
"strconv"
|
||||||
"strings"
|
"strings"
|
||||||
@@ -200,6 +201,9 @@ func ToChild(entry engine.Entry) responses.Child {
|
|||||||
child.Type = entry.Type
|
child.Type = entry.Type
|
||||||
child.UserRating = entry.UserRating
|
child.UserRating = entry.UserRating
|
||||||
child.SongCount = entry.SongCount
|
child.SongCount = entry.SongCount
|
||||||
|
// TODO Must be dynamic, based on player/transcoding config
|
||||||
|
child.TranscodedSuffix = "mp3"
|
||||||
|
child.TranscodedContentType = mime.TypeByExtension(".mp3")
|
||||||
return child
|
return child
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user