Skip to content

Commit 8f649f6

Browse files
committed
Better check for onCancel event
1 parent efd4347 commit 8f649f6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/controls/filePicker/FilePicker.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -206,7 +206,7 @@ export class FilePicker extends React.Component<IFilePickerProps, IFilePickerSta
206206
* Closes the panel
207207
*/
208208
private _handleClosePanel = () => {
209-
if (this.props.onCancel !== undefined) {
209+
if (this.props.onCancel) {
210210
this.props.onCancel();
211211
}
212212
this.setState({

0 commit comments

Comments
 (0)