diff --git a/misskaty/plugins/chatbot_ai.py b/misskaty/plugins/chatbot_ai.py index 4ffb7e3a..8e8a1bb4 100644 --- a/misskaty/plugins/chatbot_ai.py +++ b/misskaty/plugins/chatbot_ai.py @@ -93,6 +93,8 @@ async def gpt4_chatbot(self, ctx: Message, strings): ] } response = await fetch.post("https://duckduckgo.com/duckchat/v1/chat", headers=headers, json=data) + if response.status_code != 200: + return await msg.edit_msg(f"ERROR: Status Code {response.status_code}") messages = [] for line in response.text.splitlines(): if line.startswith('data:'):