lnwatcher: fix another broadcast-too-early error
This commit is contained in:
@@ -439,7 +439,7 @@ class LNWalletWatcher(LNWatcher):
|
|||||||
broadcast = True
|
broadcast = True
|
||||||
local_height = self.network.get_local_height()
|
local_height = self.network.get_local_height()
|
||||||
if sweep_info.cltv_expiry:
|
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:
|
if wanted_height - local_height > 0:
|
||||||
broadcast = False
|
broadcast = False
|
||||||
reason = 'waiting for {}: CLTV ({} > {}), prevout {}'.format(name, local_height, sweep_info.cltv_expiry, prevout)
|
reason = 'waiting for {}: CLTV ({} > {}), prevout {}'.format(name, local_height, sweep_info.cltv_expiry, prevout)
|
||||||
|
|||||||
Reference in New Issue
Block a user