We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent e87b9a1 commit 93fb914Copy full SHA for 93fb914
1 file changed
packages/fields/src/widgets/UserField.tsx
@@ -8,8 +8,8 @@ import { FieldWidgetProps } from './types';
8
* Allows selecting one or multiple users
9
*/
10
export function UserField({ value, onChange, field, readonly, ...props }: FieldWidgetProps<any>) {
11
- const userField = field as any;
12
- const multiple = userField.multiple || false;
+ const userField = (field || (props as any).schema) as any;
+ const multiple = userField?.multiple || false;
13
14
if (readonly) {
15
if (!value) return <span className="text-sm">-</span>;
0 commit comments