mirror of
https://github.com/jellyfin/jellyfin-plugin-fanart.git
synced 2024-11-26 23:20:31 +00:00
Adjust structure of the classes to v3.2 response (#56)
Co-authored-by: Aliaksei Markouski <markalex2209@gmail.com>
This commit is contained in:
parent
fbacdb243f
commit
e31206f069
@ -5,6 +5,10 @@ namespace Jellyfin.Plugin.Fanart.Dtos
|
||||
{
|
||||
public class Album
|
||||
{
|
||||
[JsonPropertyName("release_group_id")]
|
||||
public string ReleaseGroupId { get; set; }
|
||||
|
||||
|
||||
[JsonPropertyName("cdart")]
|
||||
public List<ArtistImage> CdArts { get; set; }
|
||||
|
||||
|
@ -33,6 +33,6 @@ namespace Jellyfin.Plugin.Fanart.Dtos
|
||||
public List<ArtistImage> HdmusicArts { get; set; }
|
||||
|
||||
[JsonPropertyName("albums")]
|
||||
public Dictionary<string, Album> Albums { get; set; }
|
||||
public List<Album> Albums { get; set; }
|
||||
}
|
||||
}
|
||||
|
@ -136,9 +136,9 @@ namespace Jellyfin.Plugin.Fanart.Providers
|
||||
|
||||
if (obj.Albums != null)
|
||||
{
|
||||
var album = obj.Albums.FirstOrDefault(i => string.Equals(i.Key, releaseId, StringComparison.OrdinalIgnoreCase) || string.Equals(i.Key, releaseGroupId, StringComparison.OrdinalIgnoreCase));
|
||||
var albumcovers = album.Value.AlbumCovers;
|
||||
var cdarts = album.Value.CdArts;
|
||||
var album = obj.Albums.FirstOrDefault(i => string.Equals(i.ReleaseGroupId, releaseId, StringComparison.OrdinalIgnoreCase) || string.Equals(i.ReleaseGroupId, releaseGroupId, StringComparison.OrdinalIgnoreCase));
|
||||
var albumcovers = album?.AlbumCovers;
|
||||
var cdarts = album?.CdArts;
|
||||
|
||||
if (albumcovers != null)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user