mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-19 07:04:22 +01:00
libplugin: don't return unopened channels from json_to_listpeers_channels().
This way we always have an SCID and a direction. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
@@ -3302,11 +3302,10 @@ static struct command_result *direct_pay_listpeers(struct command *cmd,
|
||||
d->chan = tal(d, struct short_channel_id_dir);
|
||||
if (chan->scid) {
|
||||
d->chan->scid = *chan->scid;
|
||||
d->chan->dir = *chan->direction;
|
||||
} else {
|
||||
d->chan->scid = *chan->alias[LOCAL];
|
||||
d->chan->dir = 0; /* Don't care. */
|
||||
}
|
||||
d->chan->dir = chan->direction;
|
||||
}
|
||||
|
||||
direct_pay_override(p);
|
||||
|
||||
Reference in New Issue
Block a user