From 0cde08e76a44d4de538060f0c0adc875648125a6 Mon Sep 17 00:00:00 2001 From: Lukas Weiss Date: Wed, 23 Nov 2022 11:42:44 +0100 Subject: [PATCH] fix error type in use-handle-form-submission (#161) --- src/components/apiHooks/useHandleFormSubmission.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/apiHooks/useHandleFormSubmission.ts b/src/components/apiHooks/useHandleFormSubmission.ts index fe4441d9..66d26e18 100644 --- a/src/components/apiHooks/useHandleFormSubmission.ts +++ b/src/components/apiHooks/useHandleFormSubmission.ts @@ -44,7 +44,7 @@ export function useHandleFormSubmission( let apiErrorMessage: string | null = null if (isAxiosError) { - const axiosError = error as AxiosError + const axiosError = error as AxiosError if (axiosError.response?.data?.errors) { const errors = joinFieldErrorMessages(