From 72865e88da52f392fff2940a05d14a4b4ae67ff9 Mon Sep 17 00:00:00 2001 From: Tulir Asokan Date: Thu, 1 Feb 2024 22:53:36 +0100 Subject: [PATCH] Fix encoding fb and interop jids --- binary/encoder.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/binary/encoder.go b/binary/encoder.go index 696443d3..21e22cf8 100644 --- a/binary/encoder.go +++ b/binary/encoder.go @@ -168,11 +168,13 @@ func (w *binaryEncoder) writeJID(jid types.JID) { w.pushByte(token.FBJID) w.write(jid.User) w.pushInt16(int(jid.Device)) + w.write(jid.Server) } else if jid.Server == types.InteropServer { w.pushByte(token.InteropJID) w.write(jid.User) w.pushInt16(int(jid.Device)) w.pushInt16(int(jid.Integrator)) + w.write(jid.Server) } else { w.pushByte(token.JIDPair) if len(jid.User) == 0 {