From ef2b448bc724cb531b68daa5d67455cbdb68d6a9 Mon Sep 17 00:00:00 2001 From: Procyonae <45432782+Procyonae@users.noreply.github.com> Date: Sun, 12 Jan 2025 15:32:15 +0000 Subject: [PATCH] Missed iterating an array --- lang/string_extractor/parsers/enchant.py | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/lang/string_extractor/parsers/enchant.py b/lang/string_extractor/parsers/enchant.py index bd0fb10057247..ccd1283c6d6fb 100644 --- a/lang/string_extractor/parsers/enchant.py +++ b/lang/string_extractor/parsers/enchant.py @@ -16,10 +16,13 @@ def parse_enchant(json, origin): if "hit_me_effect" in json: parse_effect(json["hit_me_effect"], origin) - if "special_vision" in json and "descriptions" in json["special_vision"]: - for description in json["special_vision"]["descriptions"]: - if "text" in description: - special_vision_id = description["id"] - write_text(description["text"], origin, - comment="Description of creature revealed by special" - " vision \"{}\"".format(special_vision_id)) + if "special_vision" in json: + for vision in json["special_vision"]: + if "descriptions" in vision: + for description in vision["descriptions"]: + if "text" in description: + special_vision_id = description["id"] + write_text(description["text"], origin, + comment="Description of creature revealed by " + "special vision \"{}\"" + .format(special_vision_id))