fix: fixed TS errors

This commit is contained in:
Pierre Tellier
2025-02-08 18:49:22 +01:00
parent b228b78e17
commit b5c9b40672
2 changed files with 3 additions and 4 deletions

View File

@ -34,11 +34,11 @@ axiosInstance.interceptors.response.use(
);
// TODO: spawn a error modal
function defaultApiErrorHandler(err: String){
function defaultApiErrorHandler(err: string){
addNewMessage(err, color.Red);
}
function defaultApiSuccessHandler(response: () => void){
function defaultApiSuccessHandler(response: any){
addNewMessage(response.data, color.green)
}
function callApi(endpoint: string, onSuccessHandler?: any, onErrorHandler?: any): void {