Skip to content

Commit 00d5433

Browse files
author
cesnietor
committed
use apiError instead of Error
1 parent 29001d6 commit 00d5433

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

web-app/src/screens/Console/Groups/DeleteGroup.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ import { useAppDispatch } from "../../../store";
2222
import ConfirmDialog from "../Common/ModalWrapper/ConfirmDialog";
2323
import { api } from "api";
2424
import { errorToHandler } from "api/errors";
25-
import { HttpResponse } from "api/consoleApi";
25+
import { ApiError, HttpResponse } from "api/consoleApi";
2626

2727
interface IDeleteGroup {
2828
selectedGroups: string[];
@@ -50,8 +50,8 @@ const DeleteGroup = ({
5050
.then((_) => {
5151
closeDeleteModalAndRefresh(true);
5252
})
53-
.catch(async (res: HttpResponse<void, Error>) => {
54-
const err = (await res.json()) as Error;
53+
.catch(async (res: HttpResponse<void, ApiError>) => {
54+
const err = (await res.json()) as ApiError;
5555
dispatch(setErrorSnackMessage(errorToHandler(err)));
5656
closeDeleteModalAndRefresh(false);
5757
})

0 commit comments

Comments
 (0)