diff --git a/tutorials/instagram-style-double-tap/src/DoubleTap.js b/tutorials/instagram-style-double-tap/src/DoubleTap.js index 03dc166..b059362 100644 --- a/tutorials/instagram-style-double-tap/src/DoubleTap.js +++ b/tutorials/instagram-style-double-tap/src/DoubleTap.js @@ -12,7 +12,7 @@ export default class DoubleTap extends React.Component { // https://gist.github.com/brunotavares/3c9a373ba5cd1b4ff28b handleDoubleTap = () => { const now = Date.now(); - if (this.lastTap && (now - this.lastTap) < this.props.delay) { + if (lastTap && now - lastTap < (this.props.delay || defaultProps.delay)) { this.props.onDoubleTap(); } else { this.lastTap = now;