Skip to content

Commit 4bbe252

Browse files
committed
🎨 [client] Log message type.
Signed-off-by: Oliver Tale-Yazdi <oliver@perun.network>
1 parent 9c96148 commit 4bbe252

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

client/channelconn.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ func (c *channelConn) Send(ctx context.Context, msg wire.Msg) error {
9999
if channel.Index(i) == c.idx {
100100
continue // skip own peer
101101
}
102-
c.log.WithField("peer", peer).Debugf("channelConn: publishing message: %v", msg)
102+
c.log.WithField("peer", peer).Debugf("channelConn: publishing message: %v: %+v", msg.Type(), msg)
103103
env := &wire.Envelope{
104104
Sender: c.sender(),
105105
Recipient: peer,

client/clientconn.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ func (c clientConn) nextReq(ctx context.Context) (*wire.Envelope, error) {
7474
// pubMsg publishes the given message on the wire bus, setting the own client as
7575
// the sender.
7676
func (c *clientConn) pubMsg(ctx context.Context, msg wire.Msg, rec wire.Address) error {
77-
c.Log().WithField("peer", rec).Debugf("Publishing message: %v", msg)
77+
c.Log().WithField("peer", rec).Debugf("Publishing message: %v: %+v", msg.Type(), msg)
7878
return c.bus.Publish(ctx, &wire.Envelope{
7979
Sender: c.sender,
8080
Recipient: rec,

0 commit comments

Comments
 (0)