fix(send-max): Fixed send max button error

This commit is contained in:
Daniel Gonzalez
2021-04-14 12:27:52 -04:00
parent 353a778cc4
commit 7b63ada1bc
@@ -211,13 +211,11 @@ class Send extends React.Component {
async getMaxAmount () {
try {
const bchWalletLib = _this.props.bchWallet
// Ensure the wallet UTXOs are up-to-date.
const walletAddr = bchWalletLib.walletInfo.address
await bchWalletLib.utxos.initUtxoStore(walletAddr)
const utxos = bchWalletLib.utxos.bchUtxos
const utxos = bchWalletLib.utxos.utxoStore.bchUtxos
if (!utxos.length) {
throw new Error('No BCH Utxos to spend!')
}