mirror of
https://github.com/vbenjs/vue-vben-admin.git
synced 2025-01-25 02:58:43 +08:00
解决get重试请求返回的headers造成无法成功请求的问题 (#2416)
* feat(axiosSuccess): 操作成功后根据传入提示模式进行相应 * fix(axiosRetry): 解决get重试请求返回的headers造成无法成功请求的问题
This commit is contained in:
parent
bc099041ce
commit
43c8bf0d0b
@ -16,6 +16,8 @@ export class AxiosRetry {
|
||||
return Promise.reject(error);
|
||||
}
|
||||
config.__retryCount += 1;
|
||||
//请求返回后config的header不正确造成重试请求失败,删除返回headers采用默认headers
|
||||
delete config.headers;
|
||||
return this.delay(waitTime).then(() => AxiosInstance(config));
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user