mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-19 07:04:22 +01:00
addr: handle P2SH/P2PKH in scriptpubkey encoding
Previously, returned null if a scriptpubkey was not Segwit; now handles encoding to Base58 for other types.
This commit is contained in:
committed by
Rusty Russell
parent
6f215a70e5
commit
963a1da958
@@ -301,7 +301,7 @@ static void funding_started_success(struct funding_channel *fc,
|
||||
|
||||
response = json_stream_success(cmd);
|
||||
out = encode_scriptpubkey_to_addr(cmd,
|
||||
get_chainparams(cmd->ld)->bip173_name,
|
||||
get_chainparams(cmd->ld),
|
||||
scriptPubkey);
|
||||
if (out) {
|
||||
json_add_string(response, "funding_address", out);
|
||||
|
||||
Reference in New Issue
Block a user