mirror of
https://github.com/ElementsProject/lightning.git
synced 2025-02-23 15:00:34 +01:00
json_listpeers: use channel connected flag for JSON.
If a channel is active (ie. not onchaind) and has an owner, this should be equivalent. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
parent
a134ca9659
commit
e72e54f8d1
1 changed files with 1 additions and 1 deletions
|
@ -764,7 +764,7 @@ static void gossipd_getpeers_complete(struct subd *gossip, const u8 *msg,
|
|||
connected = true;
|
||||
else {
|
||||
channel = peer_active_channel(p);
|
||||
connected = channel && channel->owner;
|
||||
connected = channel && channel->connected;
|
||||
}
|
||||
json_add_bool(response, "connected", connected);
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue