rpc: prevent spending unconfirmed funds within OpenChannel by default
In this commit, we address a slight regression in the defaults provided by the OpenChannel RPC with regards to spending unconfirmed outputs to fund funding transactions. We now add a new boolean parameter to OpenChannelRequest: SpendUnconfirmed. If set, we'll use this to indicate to the server that the funding transaction of the channel to be created can spend the wallet's unconfirmed outputs to fund it. This addition is needed because otherwise, if the caller doesn't specify a MinConfs parameter to the request, then a default of 0 will be used, which is not ideal.
This commit is contained in:
4 files changed
+475
-428
No files matched your search
@@ -2249,6 +2249,11 @@
|
||||
"type": "integer",
|
||||
"format": "int32",
|
||||
"description": "/ The minimum number of confirmations each one of your outputs used for the funding transaction must satisfy."
|
||||
},
|
||||
"spend_unconfirmed": {
|
||||
"type": "boolean",
|
||||
"format": "boolean",
|
||||
"description": "/ Whether unconfirmed outputs should be used as inputs for the funding transaction."
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
Reference in new issue
Block a user