Temporarily disable setting the Chat cached object

This commit is contained in:
Chewbacca 2022-11-04 07:36:10 -04:00
parent b510ccb865
commit 63c02cf31e

View file

@ -61,7 +61,7 @@ const updateChat = (payload: ChatPayload) => {
const currentChats = flattenPages(queryClient.getQueryData<InfiniteData<PaginatedResult<unknown>>>(ChatKeys.chatSearch()));
// Update the specific Chat query data.
queryClient.setQueryData<Chat>(ChatKeys.chat(chatId), payload as any);
// queryClient.setQueryData<Chat>(ChatKeys.chat(chatId), payload as any);
if (currentChats?.find((chat: any) => chat.id === chatId)) {
// If the chat exists in the client, let's update it.