From cfd4ecde96bedfd9688a18cddbdb28f5895595fc Mon Sep 17 00:00:00 2001 From: sacOO7 Date: Wed, 24 Jul 2024 17:59:01 +0530 Subject: [PATCH] Updated toString methods for protoMessage and PresencMessage --- ably/proto_presence_message.go | 4 ++-- ably/proto_protocol_message.go | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/ably/proto_presence_message.go b/ably/proto_presence_message.go index b1f9ea588..1a50bbc12 100644 --- a/ably/proto_presence_message.go +++ b/ably/proto_presence_message.go @@ -52,13 +52,13 @@ type PresenceMessage struct { } func (m PresenceMessage) String() string { - return fmt.Sprintf("", [...]string{ + return fmt.Sprintf("", [...]string{ "absent", "present", "enter", "leave", "update", - }[m.Action], m.ClientID, m.Data) + }[m.Action], m.ID, m.ConnectionID, m.ClientID, m.Data) } func (msg *PresenceMessage) isServerSynthesized() bool { diff --git a/ably/proto_protocol_message.go b/ably/proto_protocol_message.go index ecbb476e3..1eb62a625 100644 --- a/ably/proto_protocol_message.go +++ b/ably/proto_protocol_message.go @@ -178,8 +178,8 @@ func (msg *protocolMessage) String() string { case actionDetached: return fmt.Sprintf("(action=%q, channel=%q)", msg.Action, msg.Channel) case actionPresence, actionSync: - return fmt.Sprintf("(action=%q, id=%q, channel=%q, timestamp=%d, presenceMessages=%v)", - msg.Action, msg.ConnectionID, msg.Channel, msg.Timestamp, msg.Presence) + return fmt.Sprintf("(action=%q, id=%q, channel=%q, timestamp=%d, connectionId=%v, presenceMessages=%v)", + msg.Action, msg.ConnectionID, msg.Channel, msg.Timestamp, msg.ConnectionID, msg.Presence) case actionMessage: return fmt.Sprintf("(action=%q, id=%q, messages=%v)", msg.Action, msg.ConnectionID, msg.Messages)