Skip to content

Commit 8e2886c

Browse files
committed
Fixed: parameter check for optional function callback.
1 parent 5fb845f commit 8e2886c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/ReactInputHandler.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ function handler(event, callback) {
2727
throw new Error('react-input-handler must be bound to the component instance')
2828
}
2929

30-
if (typeof callback === 'undefined' && typeof callback !== 'function') {
30+
if (typeof callback !== 'undefined' && typeof callback !== 'function') {
3131
throw new Error('the 2nd argument of react-input-handler must be a function')
3232
}
3333

0 commit comments

Comments
 (0)