Merge pull request #1634 from open-webui/dev

fix
This commit is contained in:
Timothy Jaeryang Baek 2024-04-20 18:37:36 -07:00 committed by GitHub
commit c533ed91f5
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -322,9 +322,14 @@ OPENAI_API_BASE_URLS = [
]
OPENAI_API_KEY = ""
OPENAI_API_KEY = OPENAI_API_KEYS[
OPENAI_API_BASE_URLS.index("https://api.openai.com/v1")
]
try:
OPENAI_API_KEY = OPENAI_API_KEYS[
OPENAI_API_BASE_URLS.index("https://api.openai.com/v1")
]
except:
pass
OPENAI_API_BASE_URL = "https://api.openai.com/v1"