🐛 fix(makeprompt.py): await the moderate function call to properly handle moderation before increasing depth

This commit is contained in:
2023-08-16 09:31:00 +02:00
parent 9f257b4126
commit a02bfb5cbc

View File

@@ -153,7 +153,7 @@ async def chatgpt_process(
await chatgpt_process(self, msgs, message, api_key, prompt, model, depth)
else:
content = response.get("content", "")
if moderate(api_key, content, error_call):
if await moderate(api_key, content, error_call):
depth += 1
if depth > 2:
await message.channel.send(