fix(ui): send null (not '') for cleared organization_id on team update

AntD <Select allowClear> returns undefined when the user clears the
selection. Coalescing to "" caused the team-update payload to carry
organization_id: "" instead of null, relying on the backend to coerce
it. Send null directly so the intent is explicit at the source.
This commit is contained in:
Ryan Crabbe 2026-04-04 09:47:38 -07:00
parent 866c4a25ff
commit c495acda1b
No known key found for this signature in database

View file

@ -495,7 +495,7 @@ const TeamInfoView: React.FC<TeamInfoProps> = ({
},
...(values.policies?.length > 0 ? { policies: values.policies } : {}),
...(values.organization_id !== info.organization_id
? { organization_id: values.organization_id ?? "" }
? { organization_id: values.organization_id ?? null }
: {}),
};