the-road-to-graphql / fullstack-apollo-express-postgresql-boilerplate

💥 A sophisticated GraphQL with Apollo, Express and PostgreSQL boilerplate project.
https://roadtoreact.com
MIT License
1.2k stars 261 forks source link

session not updating after you log in ! #10

Closed Gamezpedia closed 6 years ago

Gamezpedia commented 6 years ago

hi,

i just noticed, when you log in successfully , the session is going undefined and because of it the navigation options are not getting updated after history push , but when you reload the page it will update the ui and you can see the session variables filled with the data too.

.

rwieruch commented 6 years ago

Works for me. Hm, anyone else experiencing this issue?

rwieruch commented 6 years ago

@Gamezpedia which browser are you using and is there some error showing up in the developer tools for you?

Gamezpedia commented 6 years ago

hi i am using chrome -

i put some log checks and one in withSession - for the first time when page loads i can see empty session object every where - till the server response arrives in the form of an error, and after that session object get's undefined. and after that i reloads the page and sesiion object is again filled.

Gamezpedia commented 6 years ago

well i fixed it :D i was returning an error when the authorization header was not getting any token in my Graphql server , and the session var was getting undefined .