Skip to content

Commit

Permalink
fix isMultiple check by adding compare with false
Browse files Browse the repository at this point in the history
  • Loading branch information
antpaw committed Aug 4, 2023
1 parent 1a15f93 commit 84bbdf3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/chakra-ui/src/SelectWidget/SelectWidget.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ export default function SelectWidget<T = any, S extends StrictRJSFSchema = RJSFS
})
: [];

const isMultiple = typeof multiple !== 'undefined' && Boolean(enumOptions);
const isMultiple = typeof multiple !== 'undefined' && multiple !== false && Boolean(enumOptions);
const selectedIndex = enumOptionsIndexForValue<S>(value, enumOptions, isMultiple);
const formValue: any = isMultiple
? ((selectedIndex as string[]) || []).map((i: string) => {
Expand Down

0 comments on commit 84bbdf3

Please sign in to comment.