fixed wrong id-location when getting chapters

This commit is contained in:
glax 2023-05-18 17:22:02 +02:00
parent 9eb53bb53a
commit 40242ee7ca

View File

@ -134,7 +134,7 @@ public class MangaDex : Connector
foreach (JsonObject chapter in chaptersInResult) foreach (JsonObject chapter in chaptersInResult)
{ {
JsonObject attributes = chapter!["attributes"]!.AsObject(); JsonObject attributes = chapter!["attributes"]!.AsObject();
string chapterId = attributes["id"]!.GetValue<string>(); string chapterId = chapter["id"]!.GetValue<string>();
string? title = attributes.ContainsKey("title") && attributes["title"] is not null string? title = attributes.ContainsKey("title") && attributes["title"] is not null
? attributes["title"]!.GetValue<string>() ? attributes["title"]!.GetValue<string>()