Fixed problem with logging in users and immediately needing the cookie #692
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Describe your changes
Fixed problem that if we log in a user and then request the data of that user within the same request, we would get an empty result. This was because the login cookie was only added to the response, not to the current request.
This went wrong with a customer website that uses the OCI standard for placing orders. They do POST request to certain endpoints, with login credentials and an cXML that contains the order that they want to place. We need to log them in and then immediately get the user ID from the cookie and use that to place the order for that user. This went wrong, because we couldn't read the cookie at that point.
Type of change
Please check only ONE option.
How was this tested?
This was tested via the same customer by simulating OCI order requests via PostMan. I was able to reproduce the issue and then verify that it was fixed.
Checklist before requesting a review
develop
as the base branch and notmain
, or the pull request is a hotfix that needs to be done directly onmain
Related pull requests
N/A
Link to Asana ticket
https://app.asana.com/0/1151477971646641/1208744482937211