From 56659c550ed804dcf4e3077a302772070b132671 Mon Sep 17 00:00:00 2001 From: ThomasV Date: Wed, 25 May 2022 12:45:53 +0200 Subject: [PATCH] lnwatcher: fix another broadcast-too-early error --- electrum/lnwatcher.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/electrum/lnwatcher.py b/electrum/lnwatcher.py index 8bd49273a..78e6abb78 100644 --- a/electrum/lnwatcher.py +++ b/electrum/lnwatcher.py @@ -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)