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: do not coerce undefined to null for JSON serialization #2

Merged
merged 1 commit into from
Feb 29, 2024

Conversation

achingbrain
Copy link
Member

Removes the CID decoder and disallows undefined when decoding CBOR as these do not round-trip to JSON.

Expands the test suite to be explicit about the types that are not supported.

Change checklist

  • I have performed a self-review of my own code
  • I have made corresponding changes to the documentation if necessary (this includes comments as well)
  • I have added tests that prove my fix is effective or that my feature works

Removes the CID decoder and disallows `undefined` when decoding
CBOR as these do not round-trip to JSON.

Expands the test suite to be explicit about the types that are
not supported.
@achingbrain achingbrain requested a review from a team as a code owner February 29, 2024 11:06
Copy link
Member

@2color 2color left a comment

Choose a reason for hiding this comment

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

LGTM!

@achingbrain achingbrain merged commit d36ce29 into main Feb 29, 2024
19 checks passed
@achingbrain achingbrain deleted the fix/be-explict-about-supported-cbor-types branch February 29, 2024 12:30
github-actions bot pushed a commit that referenced this pull request Feb 29, 2024
## @helia/verified-fetch [1.0.1](https://github.com/ipfs/helia-verified-fetch/compare/@helia/verified-fetch-1.0.0...@helia/verified-fetch-1.0.1) (2024-02-29)

### Bug Fixes

* do not coerce `undefined` to `null` for JSON serialization ([#2](#2)) ([d36ce29](d36ce29))
Copy link

🎉 This PR is included in version 1.0.1 🎉

The release is available on npm package (@latest dist-tag)

Your semantic-release bot 📦🚀

Copy link

🎉 This PR is included in version 1.1.0 🎉

The release is available on npm package (@latest dist-tag)

Your semantic-release bot 📦🚀

Copy link

github-actions bot commented May 9, 2024

🎉 This PR is included in version 1.0.0 🎉

The release is available on npm package (@latest dist-tag)

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants