Skip to content

Commit

Permalink
Made descriptions to return markdown instead of HTML
Browse files Browse the repository at this point in the history
  • Loading branch information
dentolos19 committed Dec 21, 2022
1 parent 17c8aeb commit 42e1b07
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 12 deletions.
5 changes: 3 additions & 2 deletions AniListNet/Objects/Character/Character.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
using Newtonsoft.Json;
using AniListNet.Helpers;
using Newtonsoft.Json;

namespace AniListNet.Objects;

Expand All @@ -8,7 +9,7 @@ public class Character
[JsonProperty("id")] public int Id { get; private set; }
[JsonProperty("name")] public CharacterName Name { get; private set; }
[JsonProperty("image")] public Image Image { get; private set; }
[JsonProperty("description")] public string? Description { get; private set; }
[JsonProperty("description")] [GqlParameter("asHtml", false)] public string? Description { get; private set; }
[JsonProperty("gender")] public string? Gender { get; private set; }
[JsonProperty("dateOfBirth")] public Date DateOfBirth { get; private set; }
[JsonProperty("age")] public string? Age { get; private set; }
Expand Down
12 changes: 3 additions & 9 deletions AniListNet/Objects/Media/Media.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,22 +13,16 @@ public class Media
[JsonProperty("title")] public MediaTitle Title { get; private set; }
[JsonProperty("type")] public MediaType Type { get; private set; }
[JsonProperty("format")] public MediaFormat? Format { get; private set; }

[JsonProperty("status")] [GqlParameter("version", 2)]
public MediaStatus Status { get; private set; }

[JsonProperty("description")] public string? Description { get; private set; }
[JsonProperty("status")] [GqlParameter("version", 2)] public MediaStatus Status { get; private set; }
[JsonProperty("description")] [GqlParameter("asHtml", false)] public string? Description { get; private set; }
[JsonProperty("startDate")] public Date StartDate { get; private set; }
[JsonProperty("endDate")] public Date EndDate { get; private set; }
[JsonProperty("season")] public MediaSeason? Season { get; private set; }
[JsonProperty("seasonYear")] public int? SeasonYear { get; private set; }
[JsonProperty("episodes")] public int? Episodes { get; private set; }
[JsonProperty("chapters")] public int? Chapters { get; private set; }
[JsonProperty("volumes")] public int? Volumes { get; private set; }

[JsonProperty("source")] [GqlParameter("version", 3)]
public MediaSource? Source { get; private set; }

[JsonProperty("source")] [GqlParameter("version", 3)] public MediaSource? Source { get; private set; }
[JsonProperty("coverImage")] public MediaCover Cover { get; private set; }
[JsonProperty("bannerImage")] public Uri? BannerImageUrl { get; private set; }
[JsonProperty("genres")] public string[] Genres { get; private set; }
Expand Down
2 changes: 1 addition & 1 deletion AniListNet/Objects/Staff/Staff.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ public class Staff
{

[JsonProperty("languageV2")] public string Language { get; private set; }
[JsonProperty("primaryOccupations")] public IReadOnlyList<string> PrimaryOccupations { get; private set; }
[JsonProperty("primaryOccupations")] public string[] PrimaryOccupations { get; private set; }
[JsonProperty("dateOfDeath")] public Date DateOfDeath { get; private set; }
[JsonProperty("yearsActive")] public int[] YearsActive { get; private set; }
[JsonProperty("homeTown")] public string? HomeTown { get; private set; }
Expand Down

0 comments on commit 42e1b07

Please sign in to comment.