mirror of
https://github.com/BerriAI/litellm.git
synced 2025-04-25 18:54:30 +00:00
fix(router.py): fix trailing slash handling for api base which contains /v1
This commit is contained in:
parent
de8f928bdd
commit
280148543f
2 changed files with 4 additions and 0 deletions
|
@ -1994,6 +1994,8 @@ class Router:
|
|||
# check if it ends with a trailing slash
|
||||
if api_base.endswith("/"):
|
||||
api_base += "v1/"
|
||||
elif api_base.endswith("/v1"):
|
||||
api_base += "/"
|
||||
else:
|
||||
api_base += "/v1/"
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue