From 536149723ec761fdabf61fcda8b8432ed94c1c5a Mon Sep 17 00:00:00 2001 From: ChaosKid42 Date: Mon, 26 Mar 2018 12:44:21 +0200 Subject: [PATCH] getNextEncryption does not honor ENCYPTION_MASK (#2899) --- .../java/eu/siacs/conversations/entities/Conversation.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/main/java/eu/siacs/conversations/entities/Conversation.java b/src/main/java/eu/siacs/conversations/entities/Conversation.java index 20f6a9246..6e91fc332 100644 --- a/src/main/java/eu/siacs/conversations/entities/Conversation.java +++ b/src/main/java/eu/siacs/conversations/entities/Conversation.java @@ -593,6 +593,9 @@ public class Conversation extends AbstractEntity implements Blockable, Comparabl public int getNextEncryption() { final int defaultEncryption; + if (!Config.supportOmemo() && !Config.supportOpenPgp()) { + return Message.ENCRYPTION_NONE; + } AxolotlService axolotlService = account.getAxolotlService(); if (contactJid.asBareJid().equals(Config.BUG_REPORTS)) { defaultEncryption = Message.ENCRYPTION_NONE;