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

Fix optional cookie #267

Merged
merged 1 commit into from
Jun 22, 2021
Merged

Conversation

gasp
Copy link
Contributor

@gasp gasp commented Jun 16, 2021

Description

prevent app crash with errors Cannot read property 'token' of undefined

Issue

  1. start the neo-push server
    yarn workspace neo-push-server start
  2. query anything

what happens

it triggers an error Cannot read property 'token' of undefined
token-property-error

expected result

it should run smoothly

itworksfine

Checklist

The following requirements should have been met (depending on the changes in the branch):

  • Documentation has been updated
  • TCK tests have been updated
  • Integration tests have been updated
  • Example applications have been updated
  • New files have copyright header
  • CLA (https://neo4j.com/developer/cla/) has been signed

this fix prevents the app from crashing id req.cookies is undefined
@darrellwarde
Copy link
Contributor

We'll just need to add to the CLA allowlist and then we'll take a look at this. 🙂 Thanks for the contribution!

Copy link
Member

@oskarhane oskarhane left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@oskarhane oskarhane merged commit af33c5e into neo4j:master Jun 22, 2021
@danstarns danstarns added the changelog PR:s labelled with this will show up in the changelog label Jun 22, 2021
@gasp gasp deleted the fix/jwt-cookie-optional-chaining branch June 22, 2021 08:34
@kristjanmik
Copy link

@OskarDamkjaer I stumbled into this bug on the 2.0.0-alpha.x release (published 21 days ago) in npm. This patch has been back-ported into the 2.0.0 branch but is still missing from the npm registry :)

@OskarDamkjaer
Copy link

@kristjanmik Is it me you seek of @oskarhane ? :)

@kristjanmik
Copy link

Yes, I'm summoning all the Oskars, sorry about that. I'm indeed calling on the power of @oskarhane.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changelog PR:s labelled with this will show up in the changelog
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants