-
-
Notifications
You must be signed in to change notification settings - Fork 986
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
incorrect session for backend route #523
Comments
Hi @nikrb thanks for the information! I'll need to get MongoDB setup to take a look, but even then, I don't really see you doing any interaction with this module directly in your code, to see if there is anything obviously wrong. Are you use this isn't a bug somewhere else, like with the Passport module? If you think it's a bug in this module and not in Passport, can you please slim down your example to make it easier to debug by removing the use of Passport and just use this module directly? |
Usually this would mean that you're not sending the session cookie with the requests to the server, so as far as the server knows, there is no session to load and creates a new one. Can you verify if the session cookie is in your browser's cookie jar and that whatever your client code is is sending the cookie to the browser? If you are making cross-domain requests or using the latest browser |
thanx for your time and the explanation. You're right of course ... after a quick search I found how to send the cookie using fetch. |
first up, as a nuub, apologies if I am presenting a red herring here.
maybe similar to #520 and #515 ... have provided a repo as requested so you can hopefully clone and run to see the issue.
Repo is here and instructions are in README.md on local-prod-test branch.
Server code is here
expected behaviour
actual behaviour
Node Version 6.11.2
Express Version 4.13.3
Session Version 1.15.6
The debug output shows the session is not correct and querying mongo before and after
clicking "authed?" button show a new session created each time.
The text was updated successfully, but these errors were encountered: