From 2c7dfe6a37ea7cf200fa70c13fd74c154166c0a0 Mon Sep 17 00:00:00 2001 From: Ryan Zhao Date: Mon, 20 Dec 2021 12:24:42 +1100 Subject: [PATCH] fix conversation screen scrolling to bottom issue --- Session/Conversations/ConversationVC.swift | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Session/Conversations/ConversationVC.swift b/Session/Conversations/ConversationVC.swift index 0a58c831c..1cafba6dd 100644 --- a/Session/Conversations/ConversationVC.swift +++ b/Session/Conversations/ConversationVC.swift @@ -460,6 +460,10 @@ final class ConversationVC : BaseVC, ConversationViewModelDelegate, OWSConversat func scrollToBottom(isAnimated: Bool) { guard !isUserScrolling else { return } + if let interactionID = viewItems.last?.interaction.uniqueId { + self.scrollToInteraction(with: interactionID, position: .top, isAnimated: isAnimated) + return + } // Ensure the view is fully up to date before we try to scroll to the bottom, since // we use the table view's bounds to determine where the bottom is. view.layoutIfNeeded()