Skip to content

Commit

Permalink
fix(VFileInput): emit single if default is undefined & !multiple (#19656
Browse files Browse the repository at this point in the history
)

fixes #19297
  • Loading branch information
yuwu9145 committed Apr 22, 2024
1 parent 9981395 commit edd311f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/vuetify/src/components/VFileInput/VFileInput.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ export const makeVFileInputProps = propsFactory({

modelValue: {
type: [Array, Object] as PropType<File[] | File>,
default: () => ([]),
default: (props: any) => props.multiple ? [] : null,
validator: (val: any) => {
return wrapInArray(val).every(v => v != null && typeof v === 'object')
},
Expand Down

0 comments on commit edd311f

Please sign in to comment.