config: pass tower manager pointer in to PopulateDependencies

In this commit, we let the explicit wtclient.Manager struct be passed in
to PopulateDependencies instead of the tower client interface. We need
to do this since we do allow the tower client interface to be nil if the
client is not active. So to avoid the golang gotcha where the interface
value will be seen as not nil even though the underlying value is nil,
we pass in the explicit pointer instead.
This commit is contained in:
Elle Mouton
2024-01-19 13:55:53 +02:00
parent ba4021cad9
commit 589cebcec2

View File

@@ -113,7 +113,7 @@ func (s *subRPCServerConfigs) PopulateDependencies(cfg *Config,
chanStateDB *channeldb.ChannelStateDB,
sweeper *sweep.UtxoSweeper,
tower *watchtower.Standalone,
towerClientMgr wtclient.ClientManager,
towerClientMgr *wtclient.Manager,
tcpResolver lncfg.TCPResolver,
genInvoiceFeatures func() *lnwire.FeatureVector,
genAmpInvoiceFeatures func() *lnwire.FeatureVector,