bithavoc / express-winston

express.js middleware for winstonjs
https://www.npmjs.com/package/express-winston
MIT License
797 stars 187 forks source link

Throws exception in strict mode #114

Closed JoergFiedler closed 8 years ago

JoergFiedler commented 8 years ago

Hi,

running node with --use-strict I get the following error.

./node_modules/express-winston/node_modules/winston/lib/winston/common.js:367
  fs.open(options.file, 'a+', 0644, function(err, fd) {
                              ^^^^
SyntaxError: Octal literals are not allowed in strict mode

This probably happens because of an outdated version of winston.

Could you please a look at this?

Thanks,

rosston commented 8 years ago

Nice catch! Fixed in 1.4.2.

I'll do the work (and the breaking version change) to upgrade winston 2 later. Thankfully, upgrading to winston 1.1 was enough to fix the core issue here.

JoergFiedler commented 8 years ago

Thank you so much.