Page MenuHomePhabricator

D13730.diff
No OneTemporary

D13730.diff

diff --git a/web/chat/thread-list-provider.js b/web/chat/thread-list-provider.js
--- a/web/chat/thread-list-provider.js
+++ b/web/chat/thread-list-provider.js
@@ -179,13 +179,24 @@
);
const threadFilter =
activeTab === 'Muted' ? threadInBackgroundChatList : threadInHomeChatList;
- const chatListDataWithoutFilter = getThreadListSearchResults(
- chatListData,
- searchText,
- threadFilter,
- threadSearchResults,
- usersSearchResults,
- loggedInUserInfo,
+ const chatListDataWithoutFilter = React.useMemo(
+ () =>
+ getThreadListSearchResults(
+ chatListData,
+ searchText,
+ threadFilter,
+ threadSearchResults,
+ usersSearchResults,
+ loggedInUserInfo,
+ ),
+ [
+ chatListData,
+ searchText,
+ threadFilter,
+ threadSearchResults,
+ usersSearchResults,
+ loggedInUserInfo,
+ ],
);
const activeTopLevelChatThreadItem = useChatThreadItem(
activeTopLevelThreadInfo,

File Metadata

Mime Type
text/plain
Expires
Wed, Nov 20, 5:41 AM (20 h, 15 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2543112
Default Alt Text
D13730.diff (999 B)

Event Timeline