From 78b29729c476392b095c3d20a88416afeb1b98c0 Mon Sep 17 00:00:00 2001 From: Ali <> Date: Wed, 27 Oct 2021 20:41:50 +0400 Subject: [PATCH] Fix edge case --- submodules/Postbox/Sources/Peer.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/submodules/Postbox/Sources/Peer.swift b/submodules/Postbox/Sources/Peer.swift index 6082c19029..c9509306f5 100644 --- a/submodules/Postbox/Sources/Peer.swift +++ b/submodules/Postbox/Sources/Peer.swift @@ -166,7 +166,7 @@ public struct PeerId: Hashable, CustomStringConvertible, Comparable, Codable { let offsetIdHighBits = (data >> (32 + 3)) & 0xffffffff let idHighBits = offsetIdHighBits << 32 - if idHighBits == 0 { + if idHighBits == 0 && namespaceBits != 0 { if let uint32Value = UInt32(exactly: idLowBits) { self.id = Id(rawValue: Int64(Int32(bitPattern: uint32Value))) } else {