added support for AUDIT, BURN, STAKE TXs to PendingTransaction wallet API

This commit is contained in:
Some Random Crypto Guy
2025-10-07 12:34:58 +01:00
parent d7a9facee9
commit c5be51053a

View File

@@ -166,9 +166,15 @@ uint64_t PendingTransactionImpl::amount() const
{
uint64_t result = 0;
for (const auto &ptx : m_pending_tx) {
if (ptx.m_tx.type == cryptonote::transaction_type::AUDIT ||
ptx.m_tx.type == cryptonote::transaction_type::BURN ||
ptx.m_tx.type == cryptonote::transaction_type::STAKE) {
result += ptx.m_tx.amount_burnt;
} else {
for (const auto &dest : ptx.dests) {
result += dest.amount;
}
}
}
return result;
}