Skip to content

Commit 0b18880

Browse files
Apply suggestions from code review
1 parent 015bb9f commit 0b18880

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

packages/utils/src/getTemplate.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,9 @@ export default function getTemplate<
2020
}
2121
// Allow templates to be customized per-field by using string keys from the registry
2222
if (
23-
Object.prototype.hasOwnProperty.call(uiOptions, name) &&
23+
Object.hasOwn(uiOptions, name)
2424
typeof uiOptions[name] === 'string' &&
25-
Object.prototype.hasOwnProperty.call(templates, uiOptions[name] as string)
25+
Object.hasOwn(templates, uiOptions[name] as string)
2626
) {
2727
const key = uiOptions[name];
2828
// Evaluating templates[key] results in TS2590: Expression produces a union type that is too complex to represent

0 commit comments

Comments
 (0)