Skip to content

Commit

Permalink
Handle case where original error is undefined
Browse files Browse the repository at this point in the history
  • Loading branch information
evmiguel committed Apr 22, 2024
1 parent ec1a8d2 commit 010a271
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/reporters/tap.js
Expand Up @@ -24,7 +24,9 @@ function dumpError({
};
}

originalError.name = name; // Restore the original name.
if (originalError) {
originalError.name = name; // Restore the original name.
}

if (type === 'ava') {
if (assertion) {
Expand Down

0 comments on commit 010a271

Please sign in to comment.