Skip to content
This repository has been archived by the owner on Jun 20, 2024. It is now read-only.

Commit

Permalink
fixed logger
Browse files Browse the repository at this point in the history
  • Loading branch information
iowar committed Oct 2, 2023
1 parent d65735f commit 8da9243
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
5 changes: 1 addition & 4 deletions pkg/p2p/libp2p/libp2p.go
Original file line number Diff line number Diff line change
Expand Up @@ -105,10 +105,7 @@ func New(opts *Options) (*Service, error) {
}

for _, addr := range host.Addrs() {
opts.Logger.With(
"addr", addr,
"host", host.ID().Pretty(),
).Info("p2p address")
opts.Logger.Info("p2p address", "addr", addr, "host_address", host.ID().Pretty())
}

ethAddress, err := GetEthAddressFromPeerID(host.ID())
Expand Down
2 changes: 1 addition & 1 deletion pkg/topology/topology.go
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ func (t *topology) Disconnected(p p2p.Peer) {
t.mu.Lock()
defer t.mu.Unlock()

t.logger.With("peer", p).Info("disconnected")
t.logger.Info("disconnected", "peer", p)

switch p.Type {
case p2p.PeerTypeBuilder:
Expand Down

0 comments on commit 8da9243

Please sign in to comment.