types: 修复类型错误
This commit is contained in:
parent
6e6beefc3c
commit
297b2c69a2
|
@ -1,6 +1,6 @@
|
|||
import axios, {
|
||||
AxiosInstance,
|
||||
AxiosRequestConfig,
|
||||
InternalAxiosRequestConfig,
|
||||
AxiosRequestHeaders,
|
||||
AxiosResponse,
|
||||
AxiosError
|
||||
|
@ -24,7 +24,7 @@ const service: AxiosInstance = axios.create({
|
|||
|
||||
// request拦截器
|
||||
service.interceptors.request.use(
|
||||
(config: AxiosRequestConfig) => {
|
||||
(config: InternalAxiosRequestConfig) => {
|
||||
if (
|
||||
config.method === 'post' &&
|
||||
(config.headers as AxiosRequestHeaders)['Content-Type'] ===
|
||||
|
|
Loading…
Reference in New Issue