Debug
This commit is contained in:
parent
5fde64ef1e
commit
16d5e4f4e7
|
@ -1617,6 +1617,9 @@ static NSTimeInterval launchStartedAt;
|
|||
[SSKEnvironment.shared.identityManager clearIdentityKey];
|
||||
[LKAPI clearRandomSnodePool];
|
||||
[self stopLongPollerIfNeeded];
|
||||
[self.lokiNewsFeedPoller stop];
|
||||
[self.lokiMessengerUpdatesFeedPoller stop];
|
||||
[LKPublicChatManager.shared stopPollers];
|
||||
[SSKEnvironment.shared.tsAccountManager resetForReregistration];
|
||||
UIViewController *rootVC = [OnboardingController new].initialViewController;
|
||||
OWSNavigationController *navigationVC = [[OWSNavigationController alloc] initWithRootViewController:rootVC];
|
||||
|
|
|
@ -89,7 +89,7 @@ final class DeviceLinksVC : UIViewController, UITableViewDataSource, UITableView
|
|||
}
|
||||
|
||||
func handleDeviceLinkAuthorized(_ deviceLink: DeviceLink) {
|
||||
dismiss(animated: true, completion: nil)
|
||||
// The modal already dismisses itself
|
||||
updateDeviceLinks()
|
||||
}
|
||||
|
||||
|
@ -100,7 +100,7 @@ final class DeviceLinksVC : UIViewController, UITableViewDataSource, UITableView
|
|||
// MARK: Interaction
|
||||
@objc private func linkNewDevice() {
|
||||
if deviceLinks.isEmpty {
|
||||
let deviceLinkingModal = DeviceLinkingModal(mode: .master, delegate: nil)
|
||||
let deviceLinkingModal = DeviceLinkingModal(mode: .master, delegate: self)
|
||||
deviceLinkingModal.modalPresentationStyle = .overFullScreen
|
||||
present(deviceLinkingModal, animated: true, completion: nil)
|
||||
} else {
|
||||
|
|
|
@ -76,12 +76,11 @@ public class OnboardingSplashViewController: OnboardingBaseViewController {
|
|||
|
||||
Analytics.shared.track("Landing Screen Viewed")
|
||||
|
||||
let userDefaults = UserDefaults.standard
|
||||
if userDefaults.bool(forKey: "wasUnlinked") {
|
||||
if UserDefaults.standard.bool(forKey: "wasUnlinked") {
|
||||
let alert = UIAlertController(title: NSLocalizedString("Device Unlinked", comment: ""), message: NSLocalizedString("Your device was unlinked successfully", comment: ""), preferredStyle: .alert)
|
||||
alert.addAction(UIAlertAction(title: NSLocalizedString("OK", comment: ""), accessibilityIdentifier: nil, style: .default, handler: nil))
|
||||
present(alert, animated: true, completion: nil)
|
||||
userDefaults.set(false, forKey: "wasUnlinked")
|
||||
UserDefaults.removeAll()
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -72,7 +72,10 @@ NS_ASSUME_NONNULL_BEGIN
|
|||
|
||||
- (instancetype)initForLocalUserWithDiameter:(NSUInteger)diameter
|
||||
{
|
||||
NSString *localNumber = [TSAccountManager localNumber];
|
||||
NSString *localNumber = [NSUserDefaults.standardUserDefaults stringForKey:@"masterDeviceHexEncodedPublicKey"];
|
||||
if (localNumber == nil) {
|
||||
localNumber = [TSAccountManager localNumber];
|
||||
}
|
||||
OWSAssertDebug(localNumber.length > 0);
|
||||
OWSAssertDebug(diameter > 0);
|
||||
|
||||
|
|
|
@ -43,6 +43,7 @@ public final class LokiPublicChatManager : NSObject {
|
|||
|
||||
@objc public func stopPollers() {
|
||||
for poller in pollers.values { poller.stop() }
|
||||
pollers.removeAll()
|
||||
isPolling = false
|
||||
}
|
||||
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
}
|
||||
|
||||
#pragma mark Settings
|
||||
- (uint)ttl { return 4 * kDayInMs; }
|
||||
- (BOOL)shouldSyncTranscript { return NO; }
|
||||
- (BOOL)shouldBeSaved { return NO; }
|
||||
|
||||
|
|
|
@ -497,7 +497,7 @@ NSString *const kNSUserDefaults_DatabaseExtensionVersionMap = @"kNSUserDefaults_
|
|||
return [unarchiver decodeObjectForKey:@"root"];
|
||||
} @catch (NSException *exception) {
|
||||
// Sync log in case we bail.
|
||||
OWSFailDebug(@"error deserializing object: %@, %@", collection, exception);
|
||||
// OWSFailDebug(@"error deserializing object: %@, %@", collection, exception);
|
||||
OWSProdCritical([OWSAnalyticsEvents storageErrorDeserialization]);
|
||||
@throw exception;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue