From db81474b855e9611c3a7da96d42818681730febb Mon Sep 17 00:00:00 2001 From: "Mr. Sanchez" Date: Sun, 21 Jul 2024 22:24:00 +0300 Subject: [PATCH] Update poept.py --- poept/poept.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/poept/poept.py b/poept/poept.py index 789ddb1..33fc21c 100644 --- a/poept/poept.py +++ b/poept/poept.py @@ -217,10 +217,10 @@ def ask(self, msg = self.driver.find_element(By.XPATH, f"(//div[@class='{self.msg_element[1:]}'])[last()]") if msg.get_attribute("data-complete") == "true": break + self.response = '\n'.join(msg.text.split('\n')[2:]) if img_output: - self.response = msg.find_element(By.CSS_SELECTOR, self.msg_image).get_attribute("src") + self.response += msg.find_element(By.CSS_SELECTOR, self.msg_image).get_attribute("src") - self.response += '\n'.join(msg.text.split('\n')[2:]) self.status = "ready" return self.response