Skip to content

Commit

Permalink
saveAdjust with updated props fix #90
Browse files Browse the repository at this point in the history
  • Loading branch information
mydu authored and boogheta committed Jul 1, 2019
1 parent 7920327 commit 9952d6d
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions app/containers/BrowserTabs/BrowserTabContent.js
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ class TabContent extends React.Component {
// Handle the case when user clicked "IN" button and does *not* want to show a popup
if (props.adjusting && props.adjusting.crawl && props.noCrawlPopup &&
(!this.props.adjusting || !this.props.adjusting.crawl)) {
this.saveAdjustChanges()
this.saveAdjustChanges(props)
}
}

Expand Down Expand Up @@ -194,9 +194,9 @@ class TabContent extends React.Component {
}
}

saveAdjustChanges = () => {
saveAdjustChanges = (props) => {
const { saveAdjustedWebentity, hideAdjustWebentity, server, corpusId,
webentity, adjusting, hideError, showError, id, disableWebentity } = this.props
webentity, adjusting, hideError, showError, id, disableWebentity } = props

// no change by default
this.setState({ setDoNotShowAgainAfterSubmit: null })
Expand Down Expand Up @@ -238,7 +238,7 @@ class TabContent extends React.Component {
key="apply-adjust" icon="check"
disabled={ saving || this.state.disableApplyButton }
title={ formatMessage({ id: adjusting.crawl ? 'save-and-crawl' : 'save' }) }
onClick={ this.saveAdjustChanges }
onClick={()=> this.saveAdjustChanges(this.props) }
/>
]
} else {
Expand Down Expand Up @@ -460,7 +460,7 @@ class TabContent extends React.Component {
const apply = e => {
e.preventDefault()
doToggle()
this.saveAdjustChanges()
this.saveAdjustChanges(this.props)
}

const cancel = e => {
Expand Down

0 comments on commit 9952d6d

Please sign in to comment.