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 bigInt deserialisation #8005

Merged
merged 6 commits into from
Oct 17, 2022
Merged

Fix bigInt deserialisation #8005

merged 6 commits into from
Oct 17, 2022

Conversation

dcousens
Copy link
Member

@dcousens dcousens commented Oct 17, 2022

If a bigInt is not parsed early, it will throw when trying to format the value in the view.
This is checked as an error condition, but the branch throwing in lieu of this is throwing when trying to JSON.stringify a BigInt.

This pull request resolves the lack of parsing in the deserialisation (bug 1) and in the event an error condition does occur, this pull request fixes the error message by not using JSON.stringify, instead showing only the typeof value types that were involved.

@vercel
Copy link

vercel bot commented Oct 17, 2022

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated
keystone-next-docs ✅ Ready (Inspect) Visit Preview Oct 17, 2022 at 6:37AM (UTC)

@changeset-bot

This comment was marked as resolved.

@vercel vercel bot temporarily deployed to Preview October 17, 2022 03:05 Inactive
@codesandbox-ci
Copy link

codesandbox-ci bot commented Oct 17, 2022

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 4da0159:

Sandbox Source
@keystone-6/sandbox Configuration

@vercel vercel bot temporarily deployed to Preview October 17, 2022 05:11 Inactive
@vercel vercel bot temporarily deployed to Preview October 17, 2022 05:27 Inactive
@vercel vercel bot temporarily deployed to Preview October 17, 2022 06:37 Inactive
@dcousens dcousens enabled auto-merge (squash) October 17, 2022 06:39
@dcousens dcousens merged commit c2b5704 into main Oct 17, 2022
@dcousens dcousens deleted the fix-bigint-deserialisation branch October 17, 2022 07:43
dcousens added a commit that referenced this pull request Oct 17, 2022
Co-authored-by: Daniel Cousens <dcousens@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants