tRename maybe_init_lightning(). Call load_data() from there - electrum - Electrum Bitcoin wallet HTML git clone https://git.parazyd.org/electrum DIR Log DIR Files DIR Refs DIR Submodules --- DIR commit 0b183444b46e6bf26622e8b41368004a73357dee DIR parent 13563697f53e4660aad29b10b3e91abd43c27955 HTML Author: ThomasV <thomasv@electrum.org> Date: Fri, 20 Nov 2020 08:35:57 +0100 Rename maybe_init_lightning(). Call load_data() from there Diffstat: M electrum/daemon.py | 3 +-- M electrum/network.py | 3 ++- 2 files changed, 3 insertions(+), 3 deletions(-) --- DIR diff --git a/electrum/daemon.py b/electrum/daemon.py t@@ -448,8 +448,7 @@ class Daemon(Logger): if self.network: self.network.start(jobs=[self.fx.run]) # prepare lightning functionality, also load channel db early - self.network.maybe_init_lightning() - self.network.channel_db.load_data() + self.network.init_channel_db() self.taskgroup = TaskGroup() asyncio.run_coroutine_threadsafe(self._run(jobs=daemon_jobs), self.asyncio_loop) DIR diff --git a/electrum/network.py b/electrum/network.py t@@ -347,12 +347,13 @@ class Network(Logger, NetworkRetryManager[ServerAddr]): def has_channel_db(self): return self.channel_db is not None - def maybe_init_lightning(self): + def init_channel_db(self): if self.channel_db is None: from . import lnrouter from . import channel_db self.channel_db = channel_db.ChannelDB(self) self.path_finder = lnrouter.LNPathFinder(self.channel_db) + self.channel_db.load_data() def start_gossip(self): if self.lngossip is None: