refactor: extract axios utility

This commit is contained in:
Carlos Valente
2025-06-22 12:15:48 +02:00
committed by Carlos Valente
parent 269091986a
commit cff73a65a5
2 changed files with 5 additions and 6 deletions
@@ -0,0 +1,5 @@
import axios from 'axios';
axios.defaults.validateStatus = (status) => {
return (status >= 200 && status < 300) || status === 304;
};
-6
View File
@@ -1,5 +1,3 @@
import axios from 'axios';
import { serverURL } from '../../externals';
// keys in tanstack store
@@ -25,7 +23,3 @@ const cssOverridePath = 'styles/override.css';
export const overrideStylesURL = `${serverURL}/${userAssetsPath}/${cssOverridePath}`;
export const projectLogoPath = `${serverURL}/${userAssetsPath}/logo`;
axios.defaults.validateStatus = (status) => {
return (status >= 200 && status < 300) || status === 304;
};