From a2477521faeb81a3ca60e38ddcd49694024e63b2 Mon Sep 17 00:00:00 2001 From: tema Date: Tue, 5 Sep 2023 00:54:53 +0300 Subject: [PATCH] Fix --- parser/utils.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/parser/utils.py b/parser/utils.py index ccb387c..e5ddfb3 100644 --- a/parser/utils.py +++ b/parser/utils.py @@ -205,9 +205,9 @@ class Helper(): def find_image(cls, document): for i in document['body']["content"]: if ("paragraph" in i) and ("elements" in i["paragraph"]): - if "inlineObjectElement" in i["paragraph"]["elements"]: + if "inlineObjectElement" in i["paragraph"]["elements"][0]: return True, cls.get_link_and_download( - i["paragraph"]["elements"] + i["paragraph"]["elements"][0] ['inlineObjectElement']['inlineObjectId'], document) return False, None