added audio url to datatype
This commit is contained in:
@@ -20,6 +20,8 @@ const ArtistSource = ObjectType("artist")
|
|||||||
|
|
||||||
type Source struct {
|
type Source struct {
|
||||||
Url string
|
Url string
|
||||||
|
AudioUrl string // will only be used when ObjectType = SongSource
|
||||||
|
|
||||||
SourceType *SourceType
|
SourceType *SourceType
|
||||||
ObjectType ObjectType
|
ObjectType ObjectType
|
||||||
}
|
}
|
||||||
@@ -38,6 +40,9 @@ func dedupeSources(inputSources []Source) []Source {
|
|||||||
if source.SourceType != nil {
|
if source.SourceType != nil {
|
||||||
deduped[mergeWithIndex].SourceType = source.SourceType
|
deduped[mergeWithIndex].SourceType = source.SourceType
|
||||||
}
|
}
|
||||||
|
if source.AudioUrl != "" {
|
||||||
|
deduped[mergeWithIndex].AudioUrl = source.AudioUrl
|
||||||
|
}
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
// just appending
|
// just appending
|
||||||
|
|||||||
Reference in New Issue
Block a user