Skip to content

Commit 1776372

Browse files
committed
Fix tests
1 parent aa2ae67 commit 1776372

File tree

2 files changed

+1
-4
lines changed

2 files changed

+1
-4
lines changed

packages/ra-ui-materialui/src/field/ArrayField.tsx

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -97,9 +97,6 @@ ArrayFieldImpl.displayName = 'ArrayFieldImpl';
9797

9898
export const ArrayField = genericMemo(ArrayFieldImpl);
9999

100-
ArrayField.propTypes = ArrayFieldImpl.propTypes;
101-
ArrayField.displayName = 'ArrayField';
102-
103100
export interface ArrayFieldProps<
104101
RecordType extends Record<string, unknown> = Record<string, any>
105102
> extends FieldProps<RecordType> {

packages/ra-ui-materialui/src/field/genericMemo.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,6 @@ export const genericMemo: <T extends FunctionComponent>(component: T) => T = <
1616
// On the memoized version so that components that inspect their children props may read them.
1717
result.propTypes = component.propTypes;
1818
result.defaultProps = component.defaultProps;
19-
result.displayName = component.displayName.replace('Impl', '');
19+
result.displayName = component.displayName?.replace('Impl', '');
2020
return result;
2121
};

0 commit comments

Comments
 (0)