Mute XHR abort errors (#31952)
This commit is contained in:
parent
a791274824
commit
7740f1a6bb
2 changed files with 10 additions and 0 deletions
|
@ -42,6 +42,9 @@ const authorizationTokenFromInitialState = (): RawAxiosRequestHeaders => {
|
|||
// eslint-disable-next-line import/no-default-export
|
||||
export default function api(withAuthorization = true) {
|
||||
return axios.create({
|
||||
transitional: {
|
||||
clarifyTimeoutError: true,
|
||||
},
|
||||
headers: {
|
||||
...csrfHeader,
|
||||
...(withAuthorization ? authorizationTokenFromInitialState() : {}),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue