Skip to content
This repository has been archived by the owner on Aug 14, 2022. It is now read-only.

Please push these codes if they are error free. It stops the Deprecation Warning in Node 9. #67

Open
desmondCTNG opened this issue Jul 16, 2021 · 0 comments

Comments

@desmondCTNG
Copy link

Instead of forcing people to use Node 8, you can simply replace two lines in decode-texture.js to solve the problem:

  1. return { extension: 'jpg' , buffer: new Buffer(tex.bytes) }; => return { extension: 'jpg' , buffer: Buffer.from(tex.bytes) };

  2. const buf = new Buffer(bytes); => const buf = Buffer.from(bytes);

Originally posted by @desmondCTNG in #3 (comment)

@desmondCTNG desmondCTNG changed the title Please push these codes if they are error free. I personally haven Please push these codes if they are error free. It solves the Depreciation Error problem in Node 9. Jul 16, 2021
@desmondCTNG desmondCTNG changed the title Please push these codes if they are error free. It solves the Depreciation Error problem in Node 9. Please push these codes if they are error free. It solves the Deprecation Error problem in Node 9. Jul 16, 2021
@desmondCTNG desmondCTNG changed the title Please push these codes if they are error free. It solves the Deprecation Error problem in Node 9. Please push these codes if they are error free. It stops the Deprecation Warning in Node 9. Jul 16, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant