Skip to content

Commit

Permalink
fix: add throwing exception if error checking failed
Browse files Browse the repository at this point in the history
  • Loading branch information
igorkamyshev committed Jan 17, 2019
1 parent e622691 commit 7b4bff8
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/index.ts
Expand Up @@ -24,8 +24,10 @@ const addErrorHandling = <Error>(
) => (...args: any[]) => {
const handleError = (err: Error) => {
if (supportsError(err)) {
middleware.dispatch(dispatchOnError())
return middleware.dispatch(dispatchOnError())
}

throw err
}

let result
Expand Down

0 comments on commit 7b4bff8

Please sign in to comment.