From 2bb5f42df84843c21e28349bb6199a6a249a7ef5 Mon Sep 17 00:00:00 2001 From: Paillat Date: Wed, 23 Aug 2023 15:24:12 +0200 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20fix(openaicaller.py):=20fix=20co?= =?UTF-8?q?ndition=20to=20check=20for=20error=5Fcall=20argument=20in=20gen?= =?UTF-8?q?erate=5Fresponse=20method?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/utils/openaicaller.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/utils/openaicaller.py b/src/utils/openaicaller.py index cdfa806..2006f61 100644 --- a/src/utils/openaicaller.py +++ b/src/utils/openaicaller.py @@ -83,7 +83,7 @@ class openai_caller: # async def generate_response(self, error_call=None, **kwargs): async def generate_response(*args, **kwargs): self = args[0] - if len(args) > 1: + if args.get("error_call", None) != None: error_call = args[1] else: