Update axios bearer token condition
This commit is contained in:
@@ -16,7 +16,7 @@ export default defineNuxtPlugin(() => {
|
||||
!config.url?.includes(API_ENDPOINTS.auth.signin) &&
|
||||
!config.url?.includes(API_ENDPOINTS.account.send_otp)
|
||||
) {
|
||||
config.headers.Authorization = `Bearer ${token.value}`;
|
||||
config.headers.Authorization = token.value ? `Bearer ${token.value}` : undefined;
|
||||
}
|
||||
|
||||
return config;
|
||||
|
||||
Reference in New Issue
Block a user