Socket.io always calls event 'join-room' on refresh page even though there is no .join() on connection.
io.of("/").adapter.on("join-room", (room, id) => {
console.log(room, id);
});
The console will log room value equals to the value of id (socket.id).
I would like to know why this is happening, and how to prevent it from happening.
I am using Socket.io with Node.js and Express.js.