otr fixes

This commit is contained in:
kosyak 2024-07-14 12:22:02 +02:00
parent 900c72ed98
commit a136138daa

View file

@ -1127,8 +1127,10 @@ public class Conversation extends AbstractEntity implements Blockable, Comparabl
defaultEncryption = Message.ENCRYPTION_NONE;
}
int encryption = this.getIntAttribute(ATTRIBUTE_NEXT_ENCRYPTION, defaultEncryption);
if (encryption == Message.ENCRYPTION_OTR || encryption < 0) {
if (encryption < 0) {
return defaultEncryption;
} else if (encryption == Message.ENCRYPTION_OTR) {
return encryption;
} else {
return encryption;
}