aboutsummaryrefslogtreecommitdiff
path: root/src/wallet
diff options
context:
space:
mode:
authorSjors Provoost <[email protected]>2019-08-14 13:32:10 +0200
committerSjors Provoost <[email protected]>2019-08-17 12:52:50 +0200
commitee950ec465b616b1f7dd14df8f77c66a817c0b64 (patch)
tree313425727e4089c7bb16e7c23e0020e7a080bdf8 /src/wallet
parentdoc: Clean out release notes post-0.18.1 (diff)
downloaddiscoin-ee950ec465b616b1f7dd14df8f77c66a817c0b64.tar.xz
discoin-ee950ec465b616b1f7dd14df8f77c66a817c0b64.zip
[rpc] walletcreatefundedpsbt: use wallet default RBF
Diffstat (limited to 'src/wallet')
-rw-r--r--src/wallet/rpcwallet.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/wallet/rpcwallet.cpp b/src/wallet/rpcwallet.cpp
index a9a8c2e18..62d21cdf7 100644
--- a/src/wallet/rpcwallet.cpp
+++ b/src/wallet/rpcwallet.cpp
@@ -4114,7 +4114,13 @@ UniValue walletcreatefundedpsbt(const JSONRPCRequest& request)
CAmount fee;
int change_position;
- CMutableTransaction rawTx = ConstructTransaction(request.params[0], request.params[1], request.params[2], request.params[3]["replaceable"]);
+ bool rbf = pwallet->m_signal_rbf;
+ const UniValue &replaceable_arg = request.params[3]["replaceable"];
+ if (!replaceable_arg.isNull()) {
+ RPCTypeCheckArgument(replaceable_arg, UniValue::VBOOL);
+ rbf = replaceable_arg.isTrue();
+ }
+ CMutableTransaction rawTx = ConstructTransaction(request.params[0], request.params[1], request.params[2], rbf);
FundTransaction(pwallet, rawTx, fee, change_position, request.params[3]);
// Make a blank psbt