mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-08-27 22:21:18 +02:00
multi: extract wallet initialization
With this commit we extract the wallet creation/unlocking and initialization completely out of the main function. This will allow us to use custom implementations in the future.
This commit is contained in:
@@ -34,6 +34,7 @@ import (
|
||||
"github.com/lightningnetwork/lnd/lnwallet/chainfee"
|
||||
"github.com/lightningnetwork/lnd/lnwire"
|
||||
"github.com/lightningnetwork/lnd/routing/chainview"
|
||||
"github.com/lightningnetwork/lnd/walletunlocker"
|
||||
)
|
||||
|
||||
// Config houses necessary fields that a chainControl instance needs to
|
||||
@@ -79,6 +80,10 @@ type Config struct {
|
||||
// BlockCache is the main cache for storing block information.
|
||||
BlockCache *blockcache.BlockCache
|
||||
|
||||
// WalletUnlockParams are the parameters that were used for unlocking
|
||||
// the main wallet.
|
||||
WalletUnlockParams *walletunlocker.WalletUnlockParams
|
||||
|
||||
// NeutrinoCS is a pointer to a neutrino ChainService. Must be non-nil if
|
||||
// using neutrino.
|
||||
NeutrinoCS *neutrino.ChainService
|
||||
|
Reference in New Issue
Block a user