ehmicky/log-process-errors

[BUG] Not compatible with Node 6

MrKumaPants opened this issue · 1 comments

Describe the bug

Package isn't compiled down to ES6.

[root@machine]# node -r log-process-errors/build/register dist/index.min.js
./node_modules/log-process-errors/build/src/options/main.js:24
const optsC={...DEFAULT_OPTS,...optsB,level};
             ^^^

SyntaxError: Unexpected token ...
    at createScript (vm.js:56:10)
    at Object.runInThisContext (vm.js:97:10)
    at Module._compile (module.js:549:28)
    at Object.Module._extensions..js (module.js:586:10)
    at Module.load (module.js:494:32)
    at tryModuleLoad (module.js:453:12)
    at Function.Module._load (module.js:445:3)
    at Module.require (module.js:504:17)
    at require (internal/module.js:20:19)
    at Object.<anonymous> (/opt/exten/ms-volume/node_modules/log-process-errors/build/src/main.js:6:11)

Hi @MrKumaPants. Thanks for reporting this.

However this module only supports Node 8 and higher: https://github.com/ehmicky/log-process-errors/blob/master/package.json#L78. More precisely the code is written for Node 11 and compiled down by Babel to Node 8.

This is because Node 6 official support will end in 3 weeks.