1
0

separate channel_db module

This commit is contained in:
ThomasV
2019-06-22 09:47:08 +02:00
parent 06b5299b0f
commit 180f6d34be
3 changed files with 596 additions and 538 deletions

View File

@@ -297,15 +297,17 @@ class Network(Logger):
self._set_status('disconnected')
# lightning network
from . import lnwatcher
from . import lnworker
from . import lnrouter
if self.config.get('lightning'):
self.channel_db = lnrouter.ChannelDB(self)
from . import lnwatcher
from . import lnworker
from . import lnrouter
from . import channel_db
self.channel_db = channel_db.ChannelDB(self)
self.path_finder = lnrouter.LNPathFinder(self.channel_db)
self.lnwatcher = lnwatcher.LNWatcher(self)
self.lngossip = lnworker.LNGossip(self)
else:
self.channel_db = None
self.lnwatcher = None
self.lngossip = None