From 8b424b06696b71cd5a33276932436008c79d9907 Mon Sep 17 00:00:00 2001 From: John Ngei Date: Fri, 14 Jun 2024 12:37:11 +0200 Subject: [PATCH] fix scroll to index error when swtiching tab on the messaging screen (#20407) --- src/status_im/contexts/chat/home/view.cljs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/status_im/contexts/chat/home/view.cljs b/src/status_im/contexts/chat/home/view.cljs index d9903aef40..18f0e5a802 100644 --- a/src/status_im/contexts/chat/home/view.cljs +++ b/src/status_im/contexts/chat/home/view.cljs @@ -93,7 +93,8 @@ {:selected-tab :tab/contacts :tab->content (empty-state-content theme)}] [rn/section-list - {:ref set-scroll-ref + {:ref (when (not-empty items) + set-scroll-ref) :key-fn :public-key :get-item-layout get-item-layout :content-inset-adjustment-behavior :never