Merge pull request #1888 from vector-im/fix_gdpr_consent_alert_after_account_creation

Fix GDPR consent alert not shown after account creation
This commit is contained in:
manuroe
2018-06-01 11:02:51 +02:00
committed by GitHub
+5 -2
View File
@@ -4019,9 +4019,12 @@ NSString *const kAppDelegateNetworkStatusDidChangeNotification = @"kAppDelegateN
{
NSString *consentURI = notification.userInfo[kMXHTTPClientUserConsentNotGivenErrorNotificationConsentURIKey];
if (consentURI
&& self.gdprConsentNotGivenAlertController == nil
&& self.gdprConsentViewController == nil)
&& self.gdprConsentNotGivenAlertController.presentingViewController == nil
&& self.gdprConsentViewController.presentingViewController == nil)
{
self.gdprConsentNotGivenAlertController = nil;
self.gdprConsentViewController = nil;
UIViewController *presentingViewController = self.window.rootViewController.presentedViewController ?: self.window.rootViewController;
__weak typeof(self) weakSelf = self;