Skip to content

Commit

Permalink
Throw err instead of Promise.reject() onResponseError
Browse files Browse the repository at this point in the history
  • Loading branch information
junzai97 committed Mar 13, 2021
1 parent dc31d2b commit 0c013a0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/webapp/app/config/axios-interceptor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ function setupAxiosInterceptors(onUnauthenticated: () => Promise<void>) {
await onUnauthenticated();
return;
}
Promise.reject(err);
throw err;
};
axios.interceptors.request.use(onRequestSuccess);
axios.interceptors.response.use(onResponseSuccess, onResponseError);
Expand Down

0 comments on commit 0c013a0

Please sign in to comment.