y59 commited on
Commit
9ddb5e9
·
verified ·
1 Parent(s): 43e57b2

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -32,7 +32,7 @@ async def sort_key(key, rate_limit, claude_model):
32
  if _key.startswith("xai-"):
33
  return get_key_xai_info(_key)
34
 
35
- if len(_key.split(':')) == 2 and _key.split(':')[1].islower() and len(_key.split(':')[1]) == 32 and "openai.azure.com" not in _key.split(':')[1]:
36
  endpoint = f"{_key.split(':')[0]}.openai.azure.com"
37
  api_key = _key.split(':')[1]
38
  return get_key_azure_info(endpoint, api_key)
 
32
  if _key.startswith("xai-"):
33
  return get_key_xai_info(_key)
34
 
35
+ if len(_key.split(':')) == 2 and _key.split(':')[1].islower() and len(_key.split(':')[1]) >= 32 and "openai.azure.com" not in _key.split(':')[1]:
36
  endpoint = f"{_key.split(':')[0]}.openai.azure.com"
37
  api_key = _key.split(':')[1]
38
  return get_key_azure_info(endpoint, api_key)