From d7ae441ee5c65945e7a1eea2fda11f1713e9cdb7 Mon Sep 17 00:00:00 2001 From: Ryan ZHAO Date: Tue, 11 Aug 2020 16:01:43 +1000 Subject: [PATCH] fix when in Settings, tapping notification won't lead to conversation view --- Signal/src/Loki/View Controllers/HomeVC.swift | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Signal/src/Loki/View Controllers/HomeVC.swift b/Signal/src/Loki/View Controllers/HomeVC.swift index 07f5dd51f..8d63bbf1d 100644 --- a/Signal/src/Loki/View Controllers/HomeVC.swift +++ b/Signal/src/Loki/View Controllers/HomeVC.swift @@ -383,6 +383,9 @@ final class HomeVC : BaseVC, UITableViewDataSource, UITableViewDelegate, UIScrol @objc func show(_ thread: TSThread, with action: ConversationViewAction, highlightedMessageID: String?, animated: Bool) { DispatchMainThreadSafe { + if let presentedVC = self.presentedViewController { + presentedVC.dismiss(animated: false, completion: nil) + } let conversationVC = ConversationViewController() conversationVC.configure(for: thread, action: action, focusMessageId: highlightedMessageID) self.navigationController?.setViewControllers([ self, conversationVC ], animated: true)