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

chore: use Buffer.from instead of deprecated new Buffer() #708

Conversation

copperwall
Copy link

I noticed the test suite has a deprecation message about using new Buffer([]) over Buffer.from([]). The buffer constructor usage was happening inside the test suite, so I thought I'd update the usage. The Node documentation says that using Buffer.from is equivalent, so I thought I'd update it. https://nodejs.org/docs/latest-v10.x/api/buffer.html#buffer_new_buffer_array

Running the test suite with this change removes the deprecation warning.

@codesandbox-ci
Copy link

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 1d3418b:

Sandbox Source
Immer sandbox Configuration

@copperwall
Copy link
Author

Oops, totally missed #706. I'll close this

@copperwall copperwall closed this Nov 25, 2020
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.

None yet

1 participant