From f81ef406fb8290832850324b0b45c9cf6022553f Mon Sep 17 00:00:00 2001 From: Joseph Garrone Date: Sat, 4 May 2024 22:57:34 +0200 Subject: [PATCH] Multivalued attributes that uses a single field have an inputType that starts with "multiselect" --- src/login/lib/useUserProfileForm.tsx | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/src/login/lib/useUserProfileForm.tsx b/src/login/lib/useUserProfileForm.tsx index 412bbb59..8763c23e 100644 --- a/src/login/lib/useUserProfileForm.tsx +++ b/src/login/lib/useUserProfileForm.tsx @@ -215,11 +215,7 @@ export function useUserProfileForm(params: ParamsOfUseUserProfileForm): ReturnTy const values = attribute.values ?? [""]; apply_validator_min_range: { - if (attribute.annotations.inputType === "multiselect") { - break apply_validator_min_range; - } - - if (attribute.annotations.inputType === "multiselect-checkboxes") { + if (attribute.annotations.inputType?.startsWith("multiselect")) { break apply_validator_min_range; } @@ -422,11 +418,7 @@ function useGetErrors(params: { kcContext: Pick