diff options
Diffstat (limited to 'lib/connection.cpp')
-rw-r--r-- | lib/connection.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/connection.cpp b/lib/connection.cpp index 5f930d57..adeb7929 100644 --- a/lib/connection.cpp +++ b/lib/connection.cpp @@ -306,9 +306,8 @@ void Connection::onSyncSuccess(SyncData &&data) { { if (accountEvent->type() == EventType::DirectChat) { - const auto usersToDCs = - unique_ptr_cast<DirectChatEvent>(accountEvent) - ->usersToDirectChats(); + const auto usersToDCs = ptrCast<DirectChatEvent>(move(accountEvent)) + ->usersToDirectChats(); DirectChatsMap removals = erase_if(d->directChats, [&usersToDCs] (auto it) { return !usersToDCs.contains(it.key()->id(), it.value()); |