mirror of
https://github.com/Steffo99/sophon.git
synced 2024-12-22 23:04:21 +00:00
🔧 Add config
parameter default value in useLoginAxios
This commit is contained in:
parent
682b6deba8
commit
d8687680a0
1 changed files with 2 additions and 2 deletions
|
@ -76,7 +76,7 @@ export function useLogin() {
|
|||
}
|
||||
|
||||
|
||||
export function useLoginAxios(config: AxiosRequestConfig) {
|
||||
export function useLoginAxios(config: AxiosRequestConfig = {}) {
|
||||
const instance = useInstance()
|
||||
const {userData} = useLogin()
|
||||
|
||||
|
@ -101,7 +101,7 @@ export function useLoginAxios(config: AxiosRequestConfig) {
|
|||
...config,
|
||||
baseURL: instance.value,
|
||||
headers: {
|
||||
...config.headers,
|
||||
...config?.headers,
|
||||
authHeader,
|
||||
}
|
||||
})
|
||||
|
|
Loading…
Reference in a new issue