добавил замену http на https
This commit is contained in:
1 parent
e7699bba77
commit
8e7a687ab3
1 file changed
+11
@@ -12,6 +12,17 @@ class ApiClient {
|
||||
},
|
||||
});
|
||||
|
||||
this.axiosInstance.interceptors.request.use(
|
||||
(config) => {
|
||||
if (config.baseURL && config.baseURL.startsWith('http://')) {
|
||||
console.error('❌ Request uses HTTP instead of HTTPS:', config.baseURL);
|
||||
config.baseURL = config.baseURL.replace('http://', 'https://');
|
||||
}
|
||||
return config;
|
||||
},
|
||||
(error) => Promise.reject(error)
|
||||
);
|
||||
|
||||
this.axiosInstance.interceptors.response.use(
|
||||
(response) => response,
|
||||
(error) => {
|
||||
|
||||
Reference in new issue
Block a user