new structure
This commit is contained in:
@@ -11,7 +11,6 @@ const apiClient = axios.create({
|
||||
|
||||
apiClient.interceptors.request.use((config) => {
|
||||
const token = Cookies.get("token");
|
||||
console.log(token)
|
||||
if (token) {
|
||||
if (config.headers && "set" in config.headers) {
|
||||
config.headers.set("Authorization", `Bearer ${token}`);
|
||||
@@ -21,3 +20,4 @@ apiClient.interceptors.request.use((config) => {
|
||||
});
|
||||
|
||||
export default apiClient;
|
||||
//IO
|
||||
|
||||
Reference in New Issue
Block a user