проверка ошибки промокода на пустую строку
This commit is contained in:
parent
1db9e54458
commit
1668cbe36b
@ -19,7 +19,7 @@ export async function activatePromocode(promocode: string) {
|
|||||||
return response.greetings;
|
return response.greetings;
|
||||||
} catch (nativeError) {
|
} catch (nativeError) {
|
||||||
const [error] = parseAxiosError(nativeError);
|
const [error] = parseAxiosError(nativeError);
|
||||||
|
|
||||||
throw new Error(error);
|
throw new Error(error);
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -200,7 +200,7 @@ function TariffPage() {
|
|||||||
setDiscounts(discounts);
|
setDiscounts(discounts);
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.catch(enqueueSnackbar);
|
.catch((error) => {if (error.message !== "" && typeof(error.message)==="string") enqueueSnackbar(error.message)})
|
||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user