mirror of
https://github.com/Nheko-Reborn/nheko.git
synced 2024-10-30 09:30:47 +03:00
Fix verification requests showing up on startup
This commit is contained in:
parent
9d6bc706ff
commit
40a3ee6eb2
1 changed files with 9 additions and 0 deletions
|
@ -275,6 +275,9 @@ TimelineViewManager::TimelineViewManager(CallManager *callManager, ChatPage *par
|
||||||
this,
|
this,
|
||||||
[this](const mtx::events::RoomEvent<mtx::events::msg::KeyVerificationRequest> &message,
|
[this](const mtx::events::RoomEvent<mtx::events::msg::KeyVerificationRequest> &message,
|
||||||
TimelineModel *model) {
|
TimelineModel *model) {
|
||||||
|
if (this->isInitialSync_)
|
||||||
|
return;
|
||||||
|
|
||||||
auto event_id = QString::fromStdString(message.event_id);
|
auto event_id = QString::fromStdString(message.event_id);
|
||||||
if (!this->dvList.contains(event_id)) {
|
if (!this->dvList.contains(event_id)) {
|
||||||
if (auto flow = DeviceVerificationFlow::NewInRoomVerification(
|
if (auto flow = DeviceVerificationFlow::NewInRoomVerification(
|
||||||
|
@ -292,6 +295,9 @@ TimelineViewManager::TimelineViewManager(CallManager *callManager, ChatPage *par
|
||||||
&ChatPage::receivedDeviceVerificationRequest,
|
&ChatPage::receivedDeviceVerificationRequest,
|
||||||
this,
|
this,
|
||||||
[this](const mtx::events::msg::KeyVerificationRequest &msg, std::string sender) {
|
[this](const mtx::events::msg::KeyVerificationRequest &msg, std::string sender) {
|
||||||
|
if (this->isInitialSync_)
|
||||||
|
return;
|
||||||
|
|
||||||
if (!msg.transaction_id)
|
if (!msg.transaction_id)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
@ -308,6 +314,9 @@ TimelineViewManager::TimelineViewManager(CallManager *callManager, ChatPage *par
|
||||||
&ChatPage::receivedDeviceVerificationStart,
|
&ChatPage::receivedDeviceVerificationStart,
|
||||||
this,
|
this,
|
||||||
[this](const mtx::events::msg::KeyVerificationStart &msg, std::string sender) {
|
[this](const mtx::events::msg::KeyVerificationStart &msg, std::string sender) {
|
||||||
|
if (this->isInitialSync_)
|
||||||
|
return;
|
||||||
|
|
||||||
if (!msg.transaction_id)
|
if (!msg.transaction_id)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue