aboutsummaryrefslogtreecommitdiff
path: root/lib/events/encryptedevent.h
diff options
context:
space:
mode:
Diffstat (limited to 'lib/events/encryptedevent.h')
-rw-r--r--lib/events/encryptedevent.h14
1 files changed, 4 insertions, 10 deletions
diff --git a/lib/events/encryptedevent.h b/lib/events/encryptedevent.h
index c838bbd8..72efffd4 100644
--- a/lib/events/encryptedevent.h
+++ b/lib/events/encryptedevent.h
@@ -39,22 +39,16 @@ public:
const QString& deviceId, const QString& sessionId);
explicit EncryptedEvent(const QJsonObject& obj);
- QString algorithm() const
- {
- QString algo = contentPart<QString>(AlgorithmKeyL);
- if (!SupportedAlgorithms.contains(algo)) {
- qWarning(MAIN) << "The EncryptedEvent's algorithm" << algo
- << "is not supported";
- }
- return algo;
- }
+ QString algorithm() const;
QByteArray ciphertext() const
{
return contentPart<QString>(CiphertextKeyL).toLatin1();
}
QJsonObject ciphertext(const QString& identityKey) const
{
- return contentPart<QJsonObject>(CiphertextKeyL).value(identityKey).toObject();
+ return contentPart<QJsonObject>(CiphertextKeyL)
+ .value(identityKey)
+ .toObject();
}
QString senderKey() const { return contentPart<QString>(SenderKeyKeyL); }