Skip to content

Commit 86d783f

Browse files
marco-ippolitoaduh95
authored andcommitted
module: rethrow amaro error message
PR-URL: #56568 Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com> Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com> Reviewed-By: Jacob Smith <jacob@frende.me> Reviewed-By: Pietro Marchini <pietro.marchini94@gmail.com> Reviewed-By: Paolo Insogna <paolo@cowtech.it>
1 parent 73ad3ca commit 86d783f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/internal/modules/typescript.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ function parseTypeScript(source, options) {
4949
try {
5050
return parse(source, options);
5151
} catch (error) {
52-
throw new ERR_INVALID_TYPESCRIPT_SYNTAX(error);
52+
throw new ERR_INVALID_TYPESCRIPT_SYNTAX(error.message);
5353
}
5454
}
5555

0 commit comments

Comments
 (0)