Skip to content

Commit b030896

Browse files
committed
Merge pull request #240 from sapegin/patch-3
Show error message, not just a stack trace
2 parents 5945c6b + 30718ac commit b030896

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/instrument.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ function computeNextEntry(reducer, action, state, error) {
7777
// In Chrome, rethrowing provides better source map support
7878
setTimeout(() => { throw err; });
7979
} else {
80-
console.error(err.stack || err);
80+
console.error(err);
8181
}
8282
}
8383

test/instrument.spec.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ describe('instrument', () => {
169169
expect(computedStates[3].error).toMatch(
170170
/Interrupted by an error up the chain/
171171
);
172-
expect(spy.calls[0].arguments[0]).toMatch(
172+
expect(spy.calls[0].arguments[0].toString()).toMatch(
173173
/ReferenceError/
174174
);
175175

0 commit comments

Comments
 (0)