AppDelegate: Do not show incoming key verification requests while authenticating.

This commit is contained in:
manuroe 2020-09-15 17:29:30 +02:00
parent b79e83e24c
commit 23056d557b
2 changed files with 13 additions and 1 deletions

View file

@ -6,7 +6,8 @@ Changes to be released in next version
🙌 Improvements
* Room: Collapse state messages on room creation (#3629).
* AuthVC: Make force PIN working for registration as well
* AuthVC: Make force PIN working for registration as well.
* AppDelegate: Do not show incoming key verification requests while authenticating.
🐛 Bugfix
* AuthVC: Fix PIN setup that broke cross-signing bootstrap.

View file

@ -4123,6 +4123,17 @@ NSString *const AppDelegateUniversalLinkDidChangeNotification = @"AppDelegateUni
return;
}
if (_masterTabBarController.authenticationInProgress)
{
NSLog(@"[AppDelegate][KeyVerification] keyVerificationNewRequestNotification: Postpone requests during the authentication process");
// 10s is quite arbitrary
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(10* NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
[self keyVerificationNewRequestNotification:notification];
});
return;
}
NSDictionary *userInfo = notification.userInfo;
MXKeyVerificationRequest *keyVerificationRequest = userInfo[MXKeyVerificationManagerNotificationRequestKey];