Skip to content

Commit 1a78ceb

Browse files
committed
replaced anonymous function with named function: warnIfUnsavedChangesCaller
1 parent 707db59 commit 1a78ceb

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

client/modules/IDE/pages/IDEView.jsx

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -204,6 +204,10 @@ class IDEView extends React.Component {
204204
}
205205
}
206206

207+
warnIfUnsavedChangesCaller(props) {
208+
return warnIfUnsavedChanges(props);
209+
}
210+
207211
render() {
208212
return (
209213
<div className="ide">
@@ -212,7 +216,7 @@ class IDEView extends React.Component {
212216
</Helmet>
213217
{this.props.toast.isVisible && <Toast />}
214218
<Nav
215-
warnIfUnsavedChanges={() => warnIfUnsavedChanges(this.props)}
219+
warnIfUnsavedChanges={this.warnIfUnsavedChangesCaller.bind(this, this.props)}
216220
cmController={this.cmController}
217221
/>
218222
<Toolbar />

0 commit comments

Comments
 (0)