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

Wrong handle of Error object #31

Closed
Asing1001 opened this issue Sep 3, 2018 · 1 comment
Closed

Wrong handle of Error object #31

Asing1001 opened this issue Sep 3, 2018 · 1 comment
Labels
important Critical path issues & PRs

Comments

@Asing1001
Copy link

Asing1001 commented Sep 3, 2018

transformed = this.format.transform(Object.assign({}, info), this.format.options);

Problem

logger.error(new Error("msg")) result in error: undefined.

Root cause

Error object stack and message is not enumerable, Object.assign will not copy non-enumerable property.

Reproduce

Object.assign({}, new Error("msg"))
// {}
@Asing1001 Asing1001 changed the title Wrong handle of Error object. Wrong handle of Error object Sep 3, 2018
@indexzero indexzero added the important Critical path issues & PRs label Jan 7, 2019
@indexzero indexzero added this to In progress in winston@3.2.0 Jan 7, 2019
@indexzero
Copy link
Member

This will be fixed shortly by winston@3.2.0. See: winstonjs/winston#1562

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
important Critical path issues & PRs
Projects
No open projects
winston@3.2.0
  
Done
Development

No branches or pull requests

2 participants