Skip to content

Commit e696a38

Browse files
committed
loopd: export Config struct
1 parent 5f70a05 commit e696a38

File tree

5 files changed

+7
-7
lines changed

5 files changed

+7
-7
lines changed

loopd/config.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ type lndConfig struct {
2828

2929
type viewParameters struct{}
3030

31-
type config struct {
31+
type Config struct {
3232
ShowVersion bool `short:"V" long:"version" description:"Display version information and exit"`
3333
Insecure bool `long:"insecure" description:"disable tls"`
3434
Network string `long:"network" description:"network to run on" choice:"regtest" choice:"testnet" choice:"mainnet" choice:"simnet"`
@@ -60,8 +60,8 @@ const (
6060
)
6161

6262
// DefaultConfig returns all default values for the Config struct.
63-
func DefaultConfig() config {
64-
return config{
63+
func DefaultConfig() Config {
64+
return Config{
6565
Network: "mainnet",
6666
RPCListen: "localhost:11010",
6767
RESTListen: "localhost:8081",

loopd/daemon.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ type listenerCfg struct {
4040

4141
// daemon runs loopd in daemon mode. It will listen for grpc connections,
4242
// execute commands and pass back swap status information.
43-
func daemon(config *config, lisCfg *listenerCfg) error {
43+
func daemon(config *Config, lisCfg *listenerCfg) error {
4444
lnd, err := lisCfg.getLnd(config.Network, config.Lnd)
4545
if err != nil {
4646
return err

loopd/start.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ type RPCConfig struct {
4747

4848
// newListenerCfg creates and returns a new listenerCfg from the passed config
4949
// and RPCConfig.
50-
func newListenerCfg(config *config, rpcCfg RPCConfig) *listenerCfg {
50+
func newListenerCfg(config *Config, rpcCfg RPCConfig) *listenerCfg {
5151
return &listenerCfg{
5252
grpcListener: func() (net.Listener, error) {
5353
// If a custom RPC listener is set, we will listen on

loopd/utils.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import (
1010
)
1111

1212
// getClient returns an instance of the swap client.
13-
func getClient(config *config, lnd *lndclient.LndServices) (*loop.Client,
13+
func getClient(config *Config, lnd *lndclient.LndServices) (*loop.Client,
1414
func(), error) {
1515

1616
storeDir, err := getStoreDir(config.Network)

loopd/view.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import (
1010
)
1111

1212
// view prints all swaps currently in the database.
13-
func view(config *config, lisCfg *listenerCfg) error {
13+
func view(config *Config, lisCfg *listenerCfg) error {
1414
chainParams, err := swap.ChainParamsFromNetwork(config.Network)
1515
if err != nil {
1616
return err

0 commit comments

Comments
 (0)