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

fix(cli/rt/error_stack): Improve message line formatting #7860

Merged

Conversation

nayeemrmn
Copy link
Collaborator

@nayeemrmn nayeemrmn commented Oct 7, 2020

Matches browsers.

Example:

const error = new Error();
error.name = undefined;
error.message = undefined;
console.log(error.stack);

// Before:
// undefined: undefined
//     at ...

// After:
// Error
//     at ...

@nayeemrmn nayeemrmn force-pushed the error-message-line-formatting branch from 1ac3c64 to 1386b1d Compare October 8, 2020 00:00
@nayeemrmn nayeemrmn force-pushed the error-message-line-formatting branch from 1386b1d to 5f4bc67 Compare October 8, 2020 00:46
Copy link
Member

@bartlomieju bartlomieju left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great! Thanks @nayeemrmn

@bartlomieju bartlomieju merged commit 986ad08 into denoland:master Oct 8, 2020
@nayeemrmn nayeemrmn deleted the error-message-line-formatting branch October 8, 2020 12:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants