-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Allow string userId in Redwood Studio generated dbAuth header #8083
Merged
Josh-Walker-GM
merged 3 commits into
redwoodjs:main
from
davidkus:rw-studio-dbauth-header
Apr 25, 2023
Merged
Allow string userId in Redwood Studio generated dbAuth header #8083
Josh-Walker-GM
merged 3 commits into
redwoodjs:main
from
davidkus:rw-studio-dbauth-header
Apr 25, 2023
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Thanks @davidkus! I'll take a look at this tomorrow and confirm with the others to get this merged 🚀 |
16 replays were recorded for 29595c8. 16 PassedrequireAuth graphql checks
|
Thanks again @davidkus! If you have any feedback about studio on the graphiql interface or any other features, good or bad, we'd love to hear about it here: https://community.redwoodjs.com/t/redwood-studio-experimental/4771 |
1 task
1 task
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Problem
When using String type as your User's
id
field (with dbAuth), your session token would include a non-numericid
. However, Redwood Studio's GraphQL explorer could not generate session token with non-numeric id, it was requiring an Int.Solution
Allow string
id
to be used in session token creation for Redwood Studio GraphQL. Check if value is numeric and if so, useparseInt
, otherwise use the provided string.Test Plan
Before (with String id):
Screen.Recording.2023-04-22.at.11.57.45.PM.mov
After (with String id):
Screen.Recording.2023-04-22.at.11.49.53.PM.mov
After (with Int id):
Screen.Recording.2023-04-22.at.11.37.43.PM.mov