1
0

lnwatcher: fix another broadcast-too-early error

This commit is contained in:
ThomasV
2022-05-25 12:45:53 +02:00
parent e99a5a7703
commit 56659c550e

View File

@@ -439,7 +439,7 @@ class LNWalletWatcher(LNWatcher):
broadcast = True
local_height = self.network.get_local_height()
if sweep_info.cltv_expiry:
wanted_height = sweep_info.cltv_expiry - local_height
wanted_height = sweep_info.cltv_expiry
if wanted_height - local_height > 0:
broadcast = False
reason = 'waiting for {}: CLTV ({} > {}), prevout {}'.format(name, local_height, sweep_info.cltv_expiry, prevout)