message: Changed balance check
diff: @@ -242,6 +242,7 @@ export default class Exchange extends Component {
  desclineOrders: [],
  pairFees: false,
  balances: false,
  + haveBalance: false,
  }
  if (config.isWidget) {
  @@ -281,7 +282,6 @@ export default class Exchange extends Component {
  })
  }
  }, 60 * 1000)
  -
  this.fetchPairFeesAndBalances()
  }
  @@ -336,21 +336,27 @@ export default class Exchange extends Component {
  this.setState({
  balances,
  })
  +
  + this.checkBalanceOnAllCurrency()
  })
  })
  })
  - // check balance on all wallets
  - const walletsArray = actions.core.getWallets()
  + }
  - for (let wallet of walletsArray) {
  - if (wallet.balance > 0) {
  + checkBalanceOnAllCurrency() {
  + const { balances } = this.state
  +
  + if (Object.keys(balances).length) {
  + for (let currency in balances) {
  + if (balances[currency] > 0) {
  this.setState({
  - balanceOnWalletsIsOk: true
  + haveBalance: true
  })
  break
  }
  }
  }
  + }
  rmScrollAdvice = () => {
  if (window.scrollY > window.innerHeight * 0.7 && this.scrollTrigger) {
  @@ -1217,6 +1223,7 @@ export default class Exchange extends Component {
  isDeclinedOffer,
  pairFees,
  balances,
  + haveBalance,
  } = this.state
  const sellCoin = haveCurrency.toUpperCase()
  @@ -1596,16 +1603,16 @@ export default class Exchange extends Component {
  >
  <FormattedMessage id="partial541" defaultMessage="Exchange now" />
  </Button>
  - {/* Creates offer */}
  + {/* Button Create offer */}
  <>
  <Button
  id="createOrderReactTooltipMessageForUser"
  - styleName={`button link-like ${this.state.balanceOnWalletsIsOk ? '' : 'noMany'}`}
  - onClick={ this.state.balanceOnWalletsIsOk ? this.createOffer : null}
  + styleName={`button link-like ${haveBalance ? '' : 'noMany'}`}
  + onClick={haveBalance ? this.createOffer : null}
  >
  <FormattedMessage id="orders128" defaultMessage="Create offer" />
  </Button>
  - { this.state.balanceOnWalletsIsOk
  + {haveBalance
  ? (
  <ReactTooltip id="createOrderReactTooltipMessageForUser" effect="solid" type="dark" place="bottom">
  <FormattedMessage
  