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

Commit

Permalink
fix(delete-button.jsx): onClick may be a boolean (#160)
Browse files Browse the repository at this point in the history
Expected onClick listener to be a function, instead got a value of boolean type.
  • Loading branch information
behzad888 authored and rnicholus committed Jan 27, 2018
1 parent 2789439 commit adfe2ad
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "react-fine-uploader",
"version": "1.0.8",
"version": "1.0.9",
"license": "MIT",
"description": "React UI components for using Fine Uploader in a React-based project.",
"author": {
Expand Down
2 changes: 1 addition & 1 deletion src/delete-button.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ class DeleteButton extends Component {
<button aria-label='delete'
className={ `react-fine-uploader-delete-button ${this.props.className || ''}` }
disabled={ !this.state.deletable || this.state.deleting }
onClick={ this.state.deletable && !this.state.deleting && this._onClick }
onClick={ (this.state.deletable && !this.state.deleting) ? this._onClick : null }
type='button'
{ ...elementProps }
>
Expand Down

0 comments on commit adfe2ad

Please sign in to comment.