From 39e3820e9e55aa4dbec5d4efb14e5c73ae18cf55 Mon Sep 17 00:00:00 2001 From: Erik Jan de Wit Date: Mon, 19 Jun 2023 08:59:45 +0200 Subject: [PATCH] use array instead of first (#20964) * use array instead of first fixes: #19638 * pr review --- js/apps/admin-ui/src/user-federation/shared/Header.tsx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/js/apps/admin-ui/src/user-federation/shared/Header.tsx b/js/apps/admin-ui/src/user-federation/shared/Header.tsx index 9c23521fec..c0f75e891e 100644 --- a/js/apps/admin-ui/src/user-federation/shared/Header.tsx +++ b/js/apps/admin-ui/src/user-federation/shared/Header.tsx @@ -69,8 +69,8 @@ export const Header = ({ !id ? ( @@ -94,12 +94,12 @@ export const Header = ({ {t("deleteProvider")} , ]} - isEnabled={field.value === "true"} + isEnabled={field.value?.[0] === "true"} onToggle={(value) => { if (!value) { toggleDisableDialog(); } else { - field.onChange(value.toString()); + field.onChange([value.toString()]); save(); } }}