From 1f64b566cb9c154faa09b906d7351fac1e85f57b Mon Sep 17 00:00:00 2001 From: Vishesh 'ironeagle' Bangotra Date: Thu, 2 Apr 2026 21:16:56 +0530 Subject: [PATCH] passing token in missing headers --- auth/src/axios.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/auth/src/axios.ts b/auth/src/axios.ts index f47154b..11b7a66 100644 --- a/auth/src/axios.ts +++ b/auth/src/axios.ts @@ -5,6 +5,9 @@ export function attachAuthInterceptors(client: AxiosInstance) { client.interceptors.request.use((config) => { const token = tokenStore.get(); if (token) { + if (!config.headers) { + (config as any).headers = {}; + } config.headers.Authorization = `Bearer ${token}`; } return config;