From 5df535611ff946cec00bdd854799a8076227f9c7 Mon Sep 17 00:00:00 2001 From: Rob Date: Thu, 18 Nov 2021 09:31:41 +0200 Subject: [PATCH] loading rooms --- components/containers/rooms/RoomContainer.tsx | 2 ++ 1 file changed, 2 insertions(+) diff --git a/components/containers/rooms/RoomContainer.tsx b/components/containers/rooms/RoomContainer.tsx index b13bfdc..1b38010 100644 --- a/components/containers/rooms/RoomContainer.tsx +++ b/components/containers/rooms/RoomContainer.tsx @@ -56,6 +56,8 @@ const RoomContainer: React.FC = () => { if(!socketInfo.connected || !socket){ dispatch(setSocket(true)); }else{ + socket.emit("requestUsers"); + socket.on("getRooms", (rooms: Room[]) => { rooms.forEach((room) => { dispatch(addRoom(room));