Skip to content

Commit 786e3c5

Browse files
committed
gui: remove unreachable AmountWithFeeExceedsBalance error
Internally, 'createTransaction' only returns the fee when the transaction creation process succeeds. This error can be reintroduced in the future in a cleaner manner when the feature becomes available at the backend level.
1 parent 71b6319 commit 786e3c5

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

src/qt/walletmodel.cpp

+1-6
Original file line numberDiff line numberDiff line change
@@ -214,12 +214,7 @@ WalletModel::SendCoinsReturn WalletModel::prepareTransaction(WalletModelTransact
214214
if (fSubtractFeeFromAmount && newTx)
215215
transaction.reassignAmounts(nChangePosRet);
216216

217-
if(!newTx)
218-
{
219-
if(!fSubtractFeeFromAmount && (total + nFeeRequired) > nBalance)
220-
{
221-
return SendCoinsReturn(AmountWithFeeExceedsBalance);
222-
}
217+
if (!newTx) {
223218
Q_EMIT message(tr("Send Coins"), QString::fromStdString(util::ErrorString(res).translated),
224219
CClientUIInterface::MSG_ERROR);
225220
return TransactionCreationFailed;

0 commit comments

Comments
 (0)