From ea69b355b5a502db9d88b262460c49ab70e571b1 Mon Sep 17 00:00:00 2001 From: glax Date: Sun, 21 May 2023 21:24:04 +0200 Subject: [PATCH] No duplicate keys --- Tranga/Connectors/MangaDex.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Tranga/Connectors/MangaDex.cs b/Tranga/Connectors/MangaDex.cs index 251bc30..cfaa60a 100644 --- a/Tranga/Connectors/MangaDex.cs +++ b/Tranga/Connectors/MangaDex.cs @@ -63,7 +63,7 @@ public class MangaDex : Connector { JsonObject altTitleObject = (JsonObject)altTitleNode!; string key = ((IDictionary)altTitleObject).Keys.ToArray()[0]; - altTitlesDict.Add(key, altTitleObject[key]!.GetValue()); + altTitlesDict.TryAdd(key, altTitleObject[key]!.GetValue()); } JsonArray tagsObject = attributes["tags"]!.AsArray();