We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 53082a0 commit 6db500cCopy full SHA for 6db500c
src/widgets/ChatMenu/ChatHistory.jsx
@@ -23,6 +23,7 @@ function ChatHistory() {
23
const navigate = useNavigate();
24
const [selectedChat] = useEvent("CHAT_SELECTED");
25
const [initChat] = useEvent("CHAT_INITIATED");
26
+ const [chatMessageResponded] = useEvent("CHAT_MESSAGE_RESPONDED", null);
27
const { chatId } = useParams();
28
const [chats, setChats] = useState([]);
29
const [, , convertChat, deleteChat] = useChat();
@@ -73,7 +74,7 @@ function ChatHistory() {
73
74
}
75
76
setChats(menu.sort((a, b) => b.created - a.created));
- }, [selectedChat, initChat]);
77
+ }, [selectedChat, initChat, chatMessageResponded]);
78
79
return (
80
<Box
0 commit comments