Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TypeError: Cannot read property 'room' of undefined #38

Open
simdie opened this issue Aug 10, 2021 · 2 comments
Open

TypeError: Cannot read property 'room' of undefined #38

simdie opened this issue Aug 10, 2021 · 2 comments

Comments

@simdie
Copy link

simdie commented Aug 10, 2021

There is an issue with sudden stoppage and disappearing of chat messages during users chatting.
It can only get to normal once browser is refreshed.

Here is the error code:

TypeError: Cannot read property 'room' of undefined
at Socket.socket.on.msg (/home/firszmuu/beyok.firstcla.net/server.js:51:16)
at Socket.emit (events.js:198:13)
at /home/firszmuu/beyok.firstcla.net/node_modules/socket.io/lib/socket.js:528:12
at process._tickCallback (internal/process/next_tick.js:61:11)
/home/firszmuu/beyok.firstcla.net/server.js:51
io.to(user.room).emit('message', formatMessage(user.username, msg));
^

Kindly assist

@Jatan88
Copy link

Jatan88 commented Apr 30, 2022

Have u got solution to this problem?

@tauseedzaman
Copy link

I did not get any errors, make sure you have installed everything as given in the readme file

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants