Skip to content
This repository was archived by the owner on Jan 14, 2021. It is now read-only.

Commit 3f5efd0

Browse files
iamchaniibluebill1049
authored andcommitted
Check target.checked is undefined (fix #41) (#42)
1 parent a792f4b commit 3f5efd0

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/index.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,9 @@ function getValue(target: any, { isCheckbox }: { isCheckbox: boolean }) {
1212

1313
return target
1414
? isCheckbox
15-
? target.checked
15+
? isUndefined(target.checked)
16+
? target.checked
17+
: target
1618
: isUndefined(target.value)
1719
? target
1820
: target.value

0 commit comments

Comments
 (0)