We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents d048324 + 2bd1854 commit ec91babCopy full SHA for ec91bab
1 file changed
1-js/10-error-handling/2-custom-errors/1-format-error/solution.md
@@ -2,7 +2,7 @@
2
class FormatError extends SyntaxError {
3
constructor(message) {
4
super(message);
5
- this.name = "FormatError";
+ this.name = this.constructor.name;
6
}
7
8
0 commit comments