mirror of
https://github.com/ElementsProject/lightning.git
synced 2024-11-19 01:43:36 +01:00
lightningd: actually deprecate old close fields.
Changelog-Deprecated: `close` `tx` and `txid` field (use `txs` and `txids`) Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
parent
c79a89d557
commit
c4cbb8671a
@ -5599,8 +5599,6 @@
|
||||
"then": {
|
||||
"additionalProperties": false,
|
||||
"required": [
|
||||
"tx",
|
||||
"txid",
|
||||
"txs",
|
||||
"txids"
|
||||
],
|
||||
|
@ -34,6 +34,8 @@ hidden: false
|
||||
| decode.blinding | Field | v24.11 | v25.05 | Renamed to `first_path_key` in BOLT 4 (available in `decode` from v24.11) |
|
||||
| onion_message_recv.blinding | Hook Field | v24.11 | v25.05 | Renamed to `first_path_key` in BOLT 4 (available in hook from v24.11) |
|
||||
| decodepay | Command | v24.11 | v25.11 | Use `decode` which is more powerful (since v23.05) |
|
||||
| close.tx | Field | v24.11 | v25.11 | Use txs array instead |
|
||||
| close.txid | Field | v24.11 | v25.11 | Use txids array instead |
|
||||
|
||||
Inevitably there are features which need to change: either to be generalized, or removed when they can no longer be supported.
|
||||
|
||||
|
@ -106,8 +106,6 @@
|
||||
"then": {
|
||||
"additionalProperties": false,
|
||||
"required": [
|
||||
"tx",
|
||||
"txid",
|
||||
"txs",
|
||||
"txids"
|
||||
],
|
||||
|
@ -58,10 +58,12 @@ resolve_one_close_command(struct close_command *cc, bool cooperative,
|
||||
struct json_stream *result = json_stream_success(cc->cmd);
|
||||
const struct bitcoin_tx *close_tx = close_txs[tal_count(close_txs) - 1];
|
||||
|
||||
if (command_deprecated_out_ok(cc->cmd, "tx", "v24.11", "v25.11"))
|
||||
json_add_tx(result, "tx", close_tx);
|
||||
if (!invalid_last_tx(close_tx)) {
|
||||
struct bitcoin_txid txid;
|
||||
bitcoin_txid(close_tx, &txid);
|
||||
if (command_deprecated_out_ok(cc->cmd, "txid", "v24.11", "v25.11"))
|
||||
json_add_txid(result, "txid", &txid);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user