Skip to content

Commit

Permalink
fix: use console.log instead of console.error (#26981)
Browse files Browse the repository at this point in the history
* fix: use `console.log` instead of `console.error`

* fix: use `console.log` instead of `console.error`
  • Loading branch information
i4pg authored May 26, 2023
1 parent 8d34032 commit f5d6eee
Showing 1 changed file with 8 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,10 @@ SyntaxError(message, fileName, lineNumber)
try {
eval("hoo bar");
} catch (e) {
console.error(e instanceof SyntaxError); // true
console.error(e.message);
console.error(e.name); // "SyntaxError"
console.error(e.stack); // Stack of the error
console.log(e instanceof SyntaxError); // true
console.log(e.message);
console.log(e.name); // "SyntaxError"
console.log(e.stack); // Stack of the error
}
```

Expand All @@ -62,10 +62,10 @@ try {
try {
throw new SyntaxError("Hello");
} catch (e) {
console.error(e instanceof SyntaxError); // true
console.error(e.message); // "Hello"
console.error(e.name); // "SyntaxError"
console.error(e.stack); // Stack of the error
console.log(e instanceof SyntaxError); // true
console.log(e.message); // "Hello"
console.log(e.name); // "SyntaxError"
console.log(e.stack); // Stack of the error
}
```

Expand Down

0 comments on commit f5d6eee

Please sign in to comment.