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

use bl@5's isBufferList to detect buffer list #105

Merged
merged 1 commit into from
Apr 12, 2022

Conversation

everett1992
Copy link
Contributor

instanceof doesn't work when using different instances of the
BufferList class, for example when different versions of buffer list are
used.

This commit upgrades to bl@5 which adds isBufferList which should work
across versions of bl.

I also moved bl to a peer dependency so it's easier for consumers to
match the bl version, and bumped the version to 6.0.0 because npm
doesn't install peer dependencies by default which could break consumers
without a bl dependency.

fixes #104

package.json Outdated
@@ -1,6 +1,6 @@
{
"name": "msgpack5",
"version": "5.3.2",
"version": "6.0.0",
Copy link
Owner

Choose a reason for hiding this comment

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

please revert this. I'll bump it when I release.

package.json Outdated
},
"standard": {
"ignore": [
"dist/"
]
},
"peerDependencies": {
"bl": "^5.0.0"
Copy link
Owner

Choose a reason for hiding this comment

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

Please bring this back as a dependency. peerDependencies create more problems than the ones they solve.

`instanceof` doesn't work when using different instances of the
BufferList class, for example when different versions of buffer list are
used.

This commit upgrades to bl@5 which adds `isBufferList` which should work
across versions of `bl`.

fixes mcollina#104
Copy link
Owner

@mcollina mcollina left a comment

Choose a reason for hiding this comment

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

lgtm

@mcollina mcollina merged commit 6c909c4 into mcollina:master Apr 12, 2022
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.

instanceof bl does not work across versions of bufferlist
2 participants