antoine-coulon / skott

All-in-one devtool to automatically analyze, search and visualize project modules and dependencies from JavaScript, TypeScript (JSX/TSX) and Node.js (ES6, CommonJS)
MIT License
645 stars 25 forks source link

fix: cannot read R_OK from undefined (node < 18.4.0) #96

Closed ACHP closed 1 year ago

ACHP commented 1 year ago

Not a big change, and depending of the node version skott want to officialy support, you might decide to close this PR, but a recent changes introduces a bug:

Importing R_OK from fs.constants is not supported for node version lower than 18.4.0

Relates to: https://github.com/nodejs/node/issues/44209#issuecomment-1211639170