From 35c9a6704d33107abb0c966f59c85a459fb0298b Mon Sep 17 00:00:00 2001 From: user Date: Tue, 2 Apr 2024 14:24:34 +0300 Subject: [PATCH] dev@locazia: mik fix --- src/pages/root/steps/presubmit-step/index.tsx | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/pages/root/steps/presubmit-step/index.tsx b/src/pages/root/steps/presubmit-step/index.tsx index 8673aad..cad985d 100644 --- a/src/pages/root/steps/presubmit-step/index.tsx +++ b/src/pages/root/steps/presubmit-step/index.tsx @@ -79,9 +79,15 @@ export const PresubmitStep = ({ prevStep }: PresubmitStepProps) => { }); WebApp.close(); - } catch (error) { + // @ts-expect-error Type issues + } catch (error: never) { console.error("An error occurred during the submission process:", error); - alert(`Возникла ошибка, ${JSON.stringify(error)}`); + + if (error?.status === 400) { + alert( + "Введенные данные неверные, проверьте правильность введенных данных.", + ); + } } };