Commit 9f197a14 authored by LNJ's avatar LNJ 💬

Fix recognition of media messages and download inside of spoilers

parent e39430bf
......@@ -116,7 +116,7 @@ void MessageHandler::handleMessage(const QXmppMessage &msg)
bodyWords.prepend(msg.outOfBandUrl());
#endif
for (const QString &word : bodyWords) {
if (!word.startsWith("https://") || !word.startsWith("http://"))
if (!word.startsWith("https://") && !word.startsWith("http://"))
continue;
// check message type by file name in link
......
......@@ -159,7 +159,6 @@ void MessageModel::updateMessage(const QString id, Message msg)
rec.setValue("edited", msg.edited);
rec.setValue("isSent", msg.isSent);
rec.setValue("isDelivered", msg.isDelivered);
rec.setValue("isSpoiler", msg.isSpoiler);
if (!msg.timestamp.isEmpty())
rec.setValue("timestamp", msg.timestamp);
if (!msg.message.isEmpty())
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment