mirror of
https://github.com/soybeanjs/soybean-admin.git
synced 2025-12-25 22:30:19 +08:00
refactor(projects): axios处理的请求结果去除网路状态
This commit is contained in:
@@ -34,7 +34,7 @@ export function handleAxiosError(axiosError: AxiosError) {
|
||||
// 请求不成功的错误
|
||||
const errorCode: ErrorStatus = axiosError.response.status as ErrorStatus;
|
||||
const msg = ERROR_STATUS[errorCode] || DEFAULT_REQUEST_ERROR_MSG;
|
||||
Object.assign(error, { code: errorCode, msg });
|
||||
Object.assign(error, { code: errorCode || DEFAULT_REQUEST_ERROR_CODE, msg });
|
||||
}
|
||||
|
||||
showErrorMsg(error);
|
||||
|
||||
Reference in New Issue
Block a user