From: tobtoht Date: Fri, 22 Oct 2021 18:28:30 +0000 (+0200) Subject: TxProofDialog: don't allow creating InProofs for out. txs, fix misleading error msg X-Git-Url: https://git.nutra.tk/v2?a=commitdiff_plain;h=dcb22245376969ed37d2b5058c0f24f6e11e43d0;p=gamesguru%2Ffeather.git TxProofDialog: don't allow creating InProofs for out. txs, fix misleading error msg --- diff --git a/src/dialog/TxProofDialog.cpp b/src/dialog/TxProofDialog.cpp index e3ac4522..a2d2a6ac 100644 --- a/src/dialog/TxProofDialog.cpp +++ b/src/dialog/TxProofDialog.cpp @@ -88,13 +88,13 @@ void TxProofDialog::selectOutProof() { m_mode = Mode::OutProof; this->resetFrames(); - if (m_OutDestinations.empty()) { - this->showWarning("This transaction did not spend any outputs owned by this wallet. Creating an OutProof is not possible."); + if (m_txKey.isEmpty()) { + this->showWarning("No transaction key stored for this transaction. Creating an OutProof is not possible."); return; } - if (m_txKey.isEmpty()) { - this->showWarning("No transaction key stored for this transaction. Creating an OutProof is not possible."); + if (m_OutDestinations.empty()) { + this->showWarning("This transaction did not send funds to any known addresses. Creating an OutProof is not possible."); return; } @@ -107,6 +107,11 @@ void TxProofDialog::selectInProof() { m_mode = Mode::InProof; this->resetFrames(); + if (m_direction == TransactionInfo::Direction_Out) { + this->showWarning("Can't create InProofs for outgoing transactions."); + return; + } + if (m_InDestinations.empty()) { this->showWarning("Your wallet did not receive any outputs in this transaction."); return;