Skip to content

Commit

Permalink
Fix Album average rating
Browse files Browse the repository at this point in the history
  • Loading branch information
geloczi committed Dec 19, 2021
1 parent 34673e2 commit 7102b61
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 7 deletions.
1 change: 1 addition & 0 deletions SynologyDotNet.AudioStation/AudioStationClient.Album.cs
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ public async Task<ApiListRessponse<AlbumList>> 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));

Expand Down
8 changes: 1 addition & 7 deletions SynologyDotNet.AudioStation/Model/Album.cs
Original file line number Diff line number Diff line change
Expand Up @@ -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; }
}
}

0 comments on commit 7102b61

Please sign in to comment.