Respond to CR.

// FREEBIE
This commit is contained in:
Matthew Chen 2017-07-05 18:12:06 -04:00
parent 97169f521a
commit ab3aa9d0ce
1 changed files with 13 additions and 17 deletions

View File

@ -436,23 +436,6 @@ static NSString *const kURLHostVerifyPrefix = @"verify";
if (getenv("runningTests_dontStartApp")) {
return;
}
[[TSAccountManager sharedInstance] ifRegistered:YES
runAsync:^{
// We're double checking that the app is active, to be sure since we
// can't verify in production env due to code
// signing.
[TSSocketManager requestSocketOpen];
dispatch_async(dispatch_get_main_queue(), ^{
[[Environment getCurrent]
.contactsManager fetchSystemContactsIfAlreadyAuthorized];
});
// This will fetch new messages, if we're using domain
// fronting.
[[PushManager sharedManager] applicationDidBecomeActive];
}];
[self removeScreenProtection];
@ -499,6 +482,7 @@ static NSString *const kURLHostVerifyPrefix = @"verify";
runAsync:^{
dispatch_async(dispatch_get_main_queue(), ^{
DDLogInfo(@"%@ running post launch block for unregistered user.", self.tag);
[TSSocketManager requestSocketOpen];
UITapGestureRecognizer *gesture =
@ -511,6 +495,18 @@ static NSString *const kURLHostVerifyPrefix = @"verify";
}];
});
[[TSAccountManager sharedInstance]
ifRegistered:YES
runAsync:^{
dispatch_async(dispatch_get_main_queue(), ^{
[[Environment getCurrent].contactsManager fetchSystemContactsIfAlreadyAuthorized];
});
// This will fetch new messages, if we're using domain
// fronting.
[[PushManager sharedManager] applicationDidBecomeActive];
}];
DDLogInfo(@"%@ applicationDidBecomeActive completed.", self.tag);
}