More error handling when joining channels with ChanKeep

This commit is contained in:
Mark Veidemanis 2022-08-02 09:01:24 +01:00
parent 98dcb99f90
commit 9b03485b69
Signed by: m
GPG Key ID: 5ACFCEED46C0904F
1 changed files with 2 additions and 0 deletions

View File

@ -136,6 +136,8 @@ def keepChannels(net, listinfo, mean, sigrelay, relay):
def joinSingle(net, channel): def joinSingle(net, channel):
eca = emptyChanAllocate(net, [channel], None, []) eca = emptyChanAllocate(net, [channel], None, [])
if not eca:
return False
if not len(eca.keys()) == 1: if not len(eca.keys()) == 1:
return False return False
num = list(eca.keys())[0] num = list(eca.keys())[0]