@@ -4547,9 +4547,9 @@ class ChatController: EditableViewController<ChatControllerView>, Notifable, Tab
45474547 }
45484548 } else {
45494549 if mode.isSavedMessagesThread {
4550- strongSelf.navigationController?.push(ChatController( context: context, chatLocation: .peer(peerId), focusTarget: .init(messageId: postId), initialAction: action) )
4550+ navigateToChat(navigation: strongSelf.navigationController, context: context, chatLocation: .peer(peerId), focusTarget: .init(messageId: postId), initialAction: action)
45514551 } else {
4552- strongSelf.navigationController?.push(ChatAdditionController( context: context, chatLocation: .peer(peerId), focusTarget: .init(messageId: postId), initialAction: action) )
4552+ navigateToChat(navigation: strongSelf.navigationController, context: context, chatLocation: .peer(peerId), focusTarget: .init(messageId: postId), initialAction: action, additional: true )
45534553 }
45544554 }
45554555 } else {
@@ -8529,7 +8529,7 @@ class ChatController: EditableViewController<ChatControllerView>, Notifable, Tab
85298529
85308530 items.append(ContextMenuItem(strings().chatSavedMessagesViewAsMessages, handler: { [weak self] in
85318531 context.engine.peers.updateSavedMessagesViewAsTopics(value: false)
8532- self?.navigationController?.push(ChatController( context: context, chatLocation: .peer(context.peerId) ))
8532+ navigateToChat(navigation: self?.navigationController, context: context, chatLocation: .peer(context.peerId))
85338533 }, itemImage: !displaySavedChatsAsTopics ? MenuAnimation.menu_check_selected.value : nil))
85348534
85358535 items.append(ContextMenuItem(strings().chatSavedMessagesViewAsChats, handler: { [weak self] in
@@ -8804,7 +8804,7 @@ class ChatController: EditableViewController<ChatControllerView>, Notifable, Tab
88048804
88058805 startSecretChatDisposable.set(signal.start(next: { [weak self] peerId in
88068806 if let strongSelf = self {
8807- strongSelf.navigationController?.push(ChatController( context: strongSelf.context, chatLocation: .peer(peerId) ))
8807+ navigateToChat(navigation: strongSelf.navigationController, context: strongSelf.context, chatLocation: .peer(peerId))
88088808 }
88098809 }))
88108810 }
0 commit comments