Fix notifications showing up repeatedly when multiple logged-in accounts are in the same room
What happens is roughly: The notification is received in one account and marked as received locally. In the other account, the event is marked as "read" in the json, which makes us delete it from the received messages. Then it is received on the first account...
This commit is contained in:
@@ -144,7 +144,6 @@ void Controller::handleNotifications(QPointer<Quotient::Connection> connection)
|
||||
for (const auto &n : notifications) {
|
||||
const auto notification = n.toObject();
|
||||
if (notification["read"].toBool()) {
|
||||
oldNotifications.removeOne(notification["event"].toObject()["event_id"].toString());
|
||||
continue;
|
||||
}
|
||||
if (oldNotifications.contains(notification["event"].toObject()["event_id"].toString())) {
|
||||
|
||||
Reference in New Issue
Block a user