summaryrefslogtreecommitdiffstats
path: root/g4f/__init__.py
diff options
context:
space:
mode:
authorTekky <98614666+xtekky@users.noreply.github.com>2023-09-23 11:55:22 +0200
committerGitHub <noreply@github.com>2023-09-23 11:55:22 +0200
commitea57fbf727520094f48c6df055983b31a9fc45a1 (patch)
tree5c7f3bd14910952c248e092b0c11a0fd9411f745 /g4f/__init__.py
parent ~ | update models list (diff)
parentDelete g4f/Provider/Vercel.py (diff)
downloadgpt4free-ea57fbf727520094f48c6df055983b31a9fc45a1.tar
gpt4free-ea57fbf727520094f48c6df055983b31a9fc45a1.tar.gz
gpt4free-ea57fbf727520094f48c6df055983b31a9fc45a1.tar.bz2
gpt4free-ea57fbf727520094f48c6df055983b31a9fc45a1.tar.lz
gpt4free-ea57fbf727520094f48c6df055983b31a9fc45a1.tar.xz
gpt4free-ea57fbf727520094f48c6df055983b31a9fc45a1.tar.zst
gpt4free-ea57fbf727520094f48c6df055983b31a9fc45a1.zip
Diffstat (limited to '')
-rw-r--r--g4f/__init__.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/g4f/__init__.py b/g4f/__init__.py
index 8fdfe21f..f3a887f6 100644
--- a/g4f/__init__.py
+++ b/g4f/__init__.py
@@ -64,7 +64,7 @@ class ChatCompletion:
model, provider = get_model_and_provider(model, provider, False)
- if not issubclass(type(provider), AsyncProvider):
+ if not issubclass(provider, AsyncProvider) and not issubclass(type(provider), AsyncProvider):
raise Exception(f"Provider: {provider.__name__} doesn't support create_async")
return await provider.create_async(model.name, messages, **kwargs)