Merge pull request #240 from sapegin/patch-3

Show error message, not just a stack trace
This commit is contained in:
Dan Abramov 2016-02-08 09:13:39 +00:00
commit b030896048
2 changed files with 2 additions and 2 deletions

View File

@ -77,7 +77,7 @@ function computeNextEntry(reducer, action, state, error) {
// In Chrome, rethrowing provides better source map support
setTimeout(() => { throw err; });
} else {
console.error(err.stack || err);
console.error(err);
}
}

View File

@ -169,7 +169,7 @@ describe('instrument', () => {
expect(computedStates[3].error).toMatch(
/Interrupted by an error up the chain/
);
expect(spy.calls[0].arguments[0]).toMatch(
expect(spy.calls[0].arguments[0].toString()).toMatch(
/ReferenceError/
);