diff options
author | luigi1111 <luigi1111w@gmail.com> | 2021-02-15 21:36:48 -0500 |
---|---|---|
committer | luigi1111 <luigi1111w@gmail.com> | 2021-02-15 21:36:48 -0500 |
commit | 4ee301c687fefe928102024bf772ee511eed7df5 (patch) | |
tree | fe7e94a965dc15e968385964279afa0eecd865c6 | |
parent | Merge pull request #6959 (diff) | |
parent | Balance includes unconfirmed payments (diff) | |
download | monero-4ee301c687fefe928102024bf772ee511eed7df5.tar.xz |
Merge pull request #6986
ee58f4f Balance includes unconfirmed payments (woodser)
-rw-r--r-- | src/wallet/wallet2.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/wallet/wallet2.cpp b/src/wallet/wallet2.cpp index d80335db8..aef9eaded 100644 --- a/src/wallet/wallet2.cpp +++ b/src/wallet/wallet2.cpp @@ -6042,6 +6042,14 @@ std::map<uint32_t, uint64_t> wallet2::balance_per_subaddress(uint32_t index_majo found->second += utx.second.m_change; } } + + for (const auto& utx: m_unconfirmed_payments) + { + if (utx.second.m_pd.m_subaddr_index.major == index_major) + { + amount_per_subaddr[utx.second.m_pd.m_subaddr_index.minor] += utx.second.m_pd.m_amount; + } + } } return amount_per_subaddr; } |