Skip to content

Commit 54549f7

Browse files
committed
refactor: split props
1 parent 39f1124 commit 54549f7

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

packages/utilities/core/src/object.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,9 @@ export function splitProps<T extends Dict>(props: T, keys: (keyof T)[]) {
3535
const result: Dict = {}
3636

3737
const keySet = new Set(keys)
38+
const ownKeys = Reflect.ownKeys(props)
3839

39-
for (const key of Reflect.ownKeys(props)) {
40+
for (const key of ownKeys) {
4041
if (keySet.has(key)) {
4142
result[key] = props[key]
4243
} else {

0 commit comments

Comments
 (0)