From 90e613f94e63ed442856bc3e3c26ac47813f1daf Mon Sep 17 00:00:00 2001 From: Daniel Gultsch Date: Thu, 19 Jan 2023 19:47:44 +0100 Subject: [PATCH] fix parsing error in Legacy caps --- .../android/xmpp/model/capabilties/LegacyCapabilities.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/im/conversations/android/xmpp/model/capabilties/LegacyCapabilities.java b/src/main/java/im/conversations/android/xmpp/model/capabilties/LegacyCapabilities.java index 25affc7e0..43836d203 100644 --- a/src/main/java/im/conversations/android/xmpp/model/capabilties/LegacyCapabilities.java +++ b/src/main/java/im/conversations/android/xmpp/model/capabilties/LegacyCapabilities.java @@ -26,8 +26,8 @@ public class LegacyCapabilities extends Extension { if (Strings.isNullOrEmpty(ver) || Strings.isNullOrEmpty(hash)) { return null; } - if (HASH_ALGORITHM.equals(hash) && BaseEncoding.base64().canDecode(hash)) { - return EntityCapabilities.EntityCapsHash.of(hash); + if (HASH_ALGORITHM.equals(hash) && BaseEncoding.base64().canDecode(ver)) { + return EntityCapabilities.EntityCapsHash.of(ver); } else { return null; }