aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRiccardo Spagni <ric@spagni.net>2019-04-18 21:59:00 +0200
committerRiccardo Spagni <ric@spagni.net>2019-04-18 21:59:01 +0200
commit55807141f29d40b9fd848d6c83bf68bf9f38aaa4 (patch)
tree37471c6bf75541e9a0dec7d28b072f0602adbb3c
parentMerge pull request #5415 (diff)
parentwallet_rpc_server: set suggested_confirmations_threshold for pool txes (diff)
downloadmonero-55807141f29d40b9fd848d6c83bf68bf9f38aaa4.tar.xz
Merge pull request #5453
71102267 wallet_rpc_server: set suggested_confirmations_threshold for pool txes (moneromooo-monero)
-rw-r--r--src/wallet/wallet_rpc_server.cpp8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/wallet/wallet_rpc_server.cpp b/src/wallet/wallet_rpc_server.cpp
index 1dd589d41..387fadb55 100644
--- a/src/wallet/wallet_rpc_server.cpp
+++ b/src/wallet/wallet_rpc_server.cpp
@@ -86,12 +86,10 @@ namespace
void set_confirmations(tools::wallet_rpc::transfer_entry &entry, uint64_t blockchain_height, uint64_t block_reward)
{
if (entry.height >= blockchain_height || (entry.height == 0 && (!strcmp(entry.type.c_str(), "pending") || !strcmp(entry.type.c_str(), "pool"))))
- {
entry.confirmations = 0;
- entry.suggested_confirmations_threshold = 0;
- return;
- }
- entry.confirmations = blockchain_height - entry.height;
+ else
+ entry.confirmations = blockchain_height - entry.height;
+
if (block_reward == 0)
entry.suggested_confirmations_threshold = 0;
else