Advanced Node Express building a chat application with a sign-in system finished. Not really :/ What am i doing wrong?

Hello all,

I’ve just ‘finished’ practice section of ‘Advanced Node Express’, there’s a lot of confusion with chat part, and all authentication related challenges act weird, tests pass, but authentication not quite working. I do NOT have fully functioning chat application, even if FCC tests/instructions say everything’s fine, and it must be there.

Authentication never works when I press social authentication button, it just hanging,
‘/chat’ redirects to root path, which to my understanding means that authentication failed.
I can see my github profle info logged to node console( on the route /auth/github/callback, i managed to get to github auth from there once), but not stuff about chat like how many users are connected or messages…ok there’s no UI rendered.

I can see FCC test user and sessions in my DB, but failed to add a user myself.
No errors in browser or node console.
What am I missing here?

code on replit

…same for me! I did pass de test but not functionally app…

When logged in (“welcome, …” page): change the url in the urlbar from …/profile to …/chat

Could somebody explain why we don’t need body-parser anymore to work with POST requests fields via req.body? It started to… just work in this course.

req.body is filled by two middleware modules. And people had questions about them for years: https://stackoverflow.com/questions/23259168/what-are-express-json-and-express-urlencoded.

That leaves only the question when it’s better to require('body-parser'), and when we’re ok to rely on native express.urlencoded(). Or both are totally same?