Skip to content
This repository has been archived by the owner on Mar 30, 2018. It is now read-only.

Commit

Permalink
check if callback is a function,
Browse files Browse the repository at this point in the history
  • Loading branch information
sureshHARDIYA committed Dec 19, 2016
1 parent c60f899 commit 5a89dc6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Modal/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ export default class Modal extends Component {
() => setTimeout(
() => {
this.modal.closePortal()
if (callback) {
if (typeof callback === 'function') {
callback()
}
},
Expand Down

0 comments on commit 5a89dc6

Please sign in to comment.