mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-11 22:51:28 +00:00
mypy linting
This commit is contained in:
parent
1411a227aa
commit
93d6aae4a3
1 changed files with 7 additions and 1 deletions
|
|
@ -1568,7 +1568,7 @@ async def _process_single_key_update(
|
|||
check_db_only=True,
|
||||
)
|
||||
|
||||
if team_obj is not None:
|
||||
if team_obj is not None and prisma_client is not None:
|
||||
await _check_team_key_limits(
|
||||
team_table=team_obj,
|
||||
data=update_key_request,
|
||||
|
|
@ -1606,6 +1606,12 @@ async def _process_single_key_update(
|
|||
)
|
||||
|
||||
# Update key in database
|
||||
if prisma_client is None:
|
||||
raise HTTPException(
|
||||
status_code=500,
|
||||
detail={"error": "Database not connected"},
|
||||
)
|
||||
|
||||
_data = {**non_default_values, "token": key_update_item.key}
|
||||
response = await prisma_client.update_data(
|
||||
token=key_update_item.key, data=_data
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue