mirror of
https://github.com/BerriAI/litellm.git
synced 2025-04-25 18:54:30 +00:00
fix(view_key_table_tsx): show abbreviated key name instead of hashed token
This commit is contained in:
parent
276d203aa2
commit
24b8abe10d
2 changed files with 13 additions and 8 deletions
|
@ -1429,7 +1429,10 @@ async def generate_key_helper_fn(
|
|||
"budget_reset_at": key_reset_at,
|
||||
"allowed_cache_controls": allowed_cache_controls,
|
||||
}
|
||||
if general_settings.get("allow_user_auth", False) == True:
|
||||
if (
|
||||
general_settings.get("allow_user_auth", False) == True
|
||||
or _has_user_setup_sso() == True
|
||||
):
|
||||
key_data["key_name"] = f"sk-...{token[-4:]}"
|
||||
saved_token = copy.deepcopy(key_data)
|
||||
if isinstance(saved_token["aliases"], str):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue