From 00f5924005258680c8f16d74aaae02193497499f Mon Sep 17 00:00:00 2001 From: Delweng Date: Sun, 18 Oct 2026 14:10:28 +0800 Subject: [PATCH] fix(ui): extract owned-param check into a named boolean Keeps the branch inside the no-long-condition-chain lint budget Signed-off-by: Delweng --- ui/litellm-dashboard/src/components/ModelInfoEditForm.tsx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ui/litellm-dashboard/src/components/ModelInfoEditForm.tsx b/ui/litellm-dashboard/src/components/ModelInfoEditForm.tsx index 6927802796f..942e6a80da4 100644 --- a/ui/litellm-dashboard/src/components/ModelInfoEditForm.tsx +++ b/ui/litellm-dashboard/src/components/ModelInfoEditForm.tsx @@ -251,10 +251,10 @@ export const toModelEditFormValues = (localModelData: any, isWildcardModel: bool litellm_credential_name: localModelData.litellm_params?.litellm_credential_name ?? null, litellm_extra_params: JSON.stringify( Object.fromEntries( - Object.entries(localModelData.litellm_params || {}).filter( - ([key, value]) => - key !== "litellm_credential_name" && key !== "weight" && key !== "order" && !isMaskedSecret(value), - ), + Object.entries(localModelData.litellm_params || {}).filter(([key, value]) => { + const ownedByDedicatedField = key === "weight" || key === "order"; + return !ownedByDedicatedField && key !== "litellm_credential_name" && !isMaskedSecret(value); + }), ), null, 2,