diff --git a/SynologyDotNet.AudioStation/AudioStationClient.Album.cs b/SynologyDotNet.AudioStation/AudioStationClient.Album.cs index d3554e8..7255837 100644 --- a/SynologyDotNet.AudioStation/AudioStationClient.Album.cs +++ b/SynologyDotNet.AudioStation/AudioStationClient.Album.cs @@ -21,6 +21,7 @@ public async Task> ListAlbumsAsync(int limit, int of { var args = new List<(string, object)>(queryParameters.Select(f => (f.Item1.ToString(), f.Item2))); args.Add(GetLibraryArg()); + args.Add(("additional", "avg_rating")); if (!string.IsNullOrWhiteSpace(artist)) args.Add(("artist", artist)); diff --git a/SynologyDotNet.AudioStation/Model/Album.cs b/SynologyDotNet.AudioStation/Model/Album.cs index b699ce9..03dc410 100644 --- a/SynologyDotNet.AudioStation/Model/Album.cs +++ b/SynologyDotNet.AudioStation/Model/Album.cs @@ -24,12 +24,6 @@ public class Album public struct AlbumAdditional { [JsonProperty("avg_rating")] - public AverageRating AverageRating { get; set; } - } - - public struct AverageRating - { - [JsonProperty("rating")] - public int Rating { get; set; } + public AvgRating AverageRating { get; set; } } }