aboutsummaryrefslogtreecommitdiff
path: root/src/rpcwallet.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/rpcwallet.cpp')
-rw-r--r--src/rpcwallet.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/rpcwallet.cpp b/src/rpcwallet.cpp
index d7c0c0ef5c..d11455e389 100644
--- a/src/rpcwallet.cpp
+++ b/src/rpcwallet.cpp
@@ -1539,7 +1539,7 @@ Value gettransaction(const Array& params, bool fHelp)
throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Invalid or non-wallet transaction id");
const CWalletTx& wtx = pwalletMain->mapWallet[hash];
- CAmount nCredit = wtx.GetCredit(filter != 0);
+ CAmount nCredit = wtx.GetCredit(filter);
CAmount nDebit = wtx.GetDebit(filter);
CAmount nNet = nCredit - nDebit;
CAmount nFee = (wtx.IsFromMe(filter) ? wtx.GetValueOut() - nDebit : 0);