watchtower/conf: abstract address normalizer to prevent import cycle
This commit is contained in:
2 files changed
+11
-4
No files matched your search
@@ -1,6 +1,8 @@
|
||||
package watchtower
|
||||
|
||||
import (
|
||||
"net"
|
||||
|
||||
"github.com/lightningnetwork/lnd/watchtower/lookout"
|
||||
"github.com/lightningnetwork/lnd/watchtower/wtserver"
|
||||
)
|
||||
@@ -12,3 +14,8 @@ type DB interface {
|
||||
lookout.DB
|
||||
wtserver.DB
|
||||
}
|
||||
|
||||
// AddressNormalizer is a function signature that allows the tower to resolve
|
||||
// TCP addresses on clear or onion networks.
|
||||
type AddressNormalizer func(addrs []string, defaultPort string,
|
||||
resolver func(string, string) (*net.TCPAddr, error)) ([]net.Addr, error)
|
||||
Reference in new issue
Block a user