fix(subsonic): populate ArtistID and AlbumID for playlists (#567)
* fix(playlist): populate ArtistID and AlbumID * update keys for CI lint config * fix lint config again * fix golden samples * prettier testdata * fix merge
This commit is contained in:
No files matched your search
@@ -88,6 +88,7 @@ func NewTCTrackByFolder(t *db.Track, parent *db.Album) *TrackChild {
|
||||
}
|
||||
if t.Album != nil {
|
||||
trCh.Album = t.Album.RightPath
|
||||
trCh.AlbumID = t.Album.SID()
|
||||
}
|
||||
if t.TrackStar != nil {
|
||||
trCh.Starred = &t.TrackStar.StarDate
|
||||
@@ -102,6 +103,9 @@ func NewTCTrackByFolder(t *db.Track, parent *db.Album) *TrackChild {
|
||||
trCh.Genres = append(trCh.Genres, &GenreRef{Name: g.Name})
|
||||
}
|
||||
for _, a := range t.Artists {
|
||||
if a.Name == t.TagTrackArtist {
|
||||
trCh.ArtistID = a.SID()
|
||||
}
|
||||
trCh.Artists = append(trCh.Artists, &ArtistRef{ID: a.SID(), Name: a.Name})
|
||||
}
|
||||
if t.ReplayGainTrackGain != 0 || t.ReplayGainAlbumGain != 0 {
|
||||
|
||||
Reference in New Issue
Block a user