@@ -141,7 +141,8 @@ type LightningTerminal struct {
141
141
wg sync.WaitGroup
142
142
lndErrChan chan error
143
143
144
- lndClient * lndclient.GrpcLndServices
144
+ lndClient * lndclient.GrpcLndServices
145
+ basicClient lnrpc.LightningClient
145
146
146
147
faradayServer * frdrpc.RPCServer
147
148
faradayStarted bool
@@ -406,7 +407,6 @@ func (g *LightningTerminal) Run() error {
406
407
// servers that lnd started.
407
408
func (g * LightningTerminal ) startSubservers () error {
408
409
var (
409
- basicClient lnrpc.LightningClient
410
410
insecure bool
411
411
clientOptions []lndclient.BasicClientOption
412
412
)
@@ -438,7 +438,7 @@ func (g *LightningTerminal) startSubservers() error {
438
438
// We'll need a basic client and a full client because not all
439
439
// subservers have the same requirements.
440
440
var err error
441
- basicClient , err = lndclient .NewBasicClient (
441
+ g . basicClient , err = lndclient .NewBasicClient (
442
442
host , tlsPath , path .Dir (macPath ), string (network ),
443
443
clientOptions ... ,
444
444
)
@@ -498,7 +498,7 @@ func (g *LightningTerminal) startSubservers() error {
498
498
// faraday, loop, and pool, all at the same time.
499
499
ctx := context .Background ()
500
500
superMacaroon , err := bakeSuperMacaroon (
501
- ctx , basicClient , 0 , getAllPermissions (), nil ,
501
+ ctx , g . basicClient , 0 , getAllPermissions (), nil ,
502
502
)
503
503
if err != nil {
504
504
return err
@@ -546,7 +546,7 @@ func (g *LightningTerminal) startSubservers() error {
546
546
547
547
if ! g .cfg .poolRemote {
548
548
err = g .poolServer .StartAsSubserver (
549
- basicClient , g .lndClient , createDefaultMacaroons ,
549
+ g . basicClient , g .lndClient , createDefaultMacaroons ,
550
550
)
551
551
if err != nil {
552
552
return err
0 commit comments