After writing my code, testing it, looking over the complete code linked with “here” to make sure that I wrote the code correctly, and then testing it, it passes the tests.
But for the console.log('user ' + socket.request.user.username + ' connected');
I’m getting undefined.
I saw:
failed connection to socket.io: No session found
BEGINNING OF SOCKET DATA: (additional console log I used to see what’s going on)
{ logged_in: false } (console.log for socket.request.user )
END OF SOCKET DATA (additional console log I used to see what’s going on)
I’ve been trying to figure out what is going on, but I haven’t been able to.
Here is the tutorial page: Advanced Node and Express - Authentication with Socket.IO | Learn | freeCodeCamp.org
Here’s the link to my project: https://boilerplate-advancednode.nwbraycode.repl.co