This commit is contained in:
Proddy
2023-07-08 14:10:08 +02:00
parent 1b27ccf70e
commit eb6e8d0c93
2 changed files with 1 additions and 3 deletions

View File

@@ -13,7 +13,6 @@ import Security from 'framework/security/Security';
import System from 'framework/system/System';
const AuthenticatedRouting: FC = () => (
// TODO not sure if this is needed, to redirect on 401. If so add incerceptor to Alova
// const location = useLocation();
// const navigate = useNavigate();
// const handleApiResponseError = useCallback(

View File

@@ -46,8 +46,7 @@ export const alovaInstance = createAlova({
}
// Interceptor for request failure. This interceptor will be entered when the request is wrong.
// TODO how best to handle http errors like 401 (unauthorized)
// but I think this is handled correctly in AppRouting? See AuthenticatedRouting()
// http errors like 401 (unauthorized) are handled either in the methods or AuthenticatedRouting()
// onError: (error, method) => {
// alert(error.message);
// }