mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2025-01-08 19:59:29 +00:00
handle assert nicely
This commit is contained in:
parent
99e802b59e
commit
4dc920772a
1 changed files with 6 additions and 1 deletions
|
@ -224,7 +224,12 @@ mixin ElectrumXInterface<T extends ElectrumXCurrencyInterface>
|
|||
final utxoSigningData = await fetchBuildTxData(utxoObjectsToUse);
|
||||
|
||||
if (isSendAll || isSendAllCoinControlUtxos) {
|
||||
assert(satoshiAmountToSend == satoshisBeingUsed);
|
||||
if (satoshiAmountToSend != satoshisBeingUsed) {
|
||||
throw Exception(
|
||||
"Something happened that should never actually happen. "
|
||||
"Please report this error to the developers.",
|
||||
);
|
||||
}
|
||||
return await _sendAllBuilder(
|
||||
txData: txData,
|
||||
recipientAddress: recipientAddress,
|
||||
|
|
Loading…
Reference in a new issue