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

Deprecated API in Node.js 22+ #908

Closed
toast-ts opened this issue May 5, 2024 · 3 comments
Closed

Deprecated API in Node.js 22+ #908

toast-ts opened this issue May 5, 2024 · 3 comments

Comments

@toast-ts
Copy link

toast-ts commented May 5, 2024

Is your feature request related to a problem? Please describe.
When I updated my Node.js to 22.0.0, I have now received a deprecation warning for util._extend,
as this is something they deprecated several versions back but only seen the warning in Node22 and not the versions below it like Node21 doesn't seem to display it.

(node:35) [DEP0060] DeprecationWarning: The `util._extend` API is deprecated. Please use Object.assign() instead.
(Use `node --trace-deprecation ...` to show where the warning was created)

Describe the solution you'd like
Replace the util._extend usage with Object.assign(), this is located in lib/util.js for 3 lines containing this.

Describe alternatives you've considered
I have not thought of an alternative solution nor have I allocated my spare time to solve this myself.

Additional context
N/A.

@sebhildebrandt
Copy link
Owner

@toast-ts Ok, I will have a look at it ... I have to check also if the alternative would work back also in Node 4.0 as this is the oldest supported version of this library. Otherwise it would be a breaking change witch would then require a major version change ... I am already working intensively on a fully rewritten version 6.0 (written in TypeScript).

@sebhildebrandt
Copy link
Owner

@toast-ts ... Ok I fixed it ... version 5.22.8 just published. Can you check it on your side?

@toast-ts
Copy link
Author

toast-ts commented May 5, 2024

Yes, it is fixed, no deprecation warning in console.
Thank you.

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

No branches or pull requests

2 participants