From adad9297692fd8837b9a1f62a391ee1cbe42dc73 Mon Sep 17 00:00:00 2001 From: vladtechno Date: Thu, 18 Jun 2026 20:33:46 +1000 Subject: [PATCH] feat(driver-pwa): friendly toast on 429 (rate-limited code request) Co-Authored-By: claude-flow --- driver-pwa/frontend/src/pages/LoginPage.tsx | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/driver-pwa/frontend/src/pages/LoginPage.tsx b/driver-pwa/frontend/src/pages/LoginPage.tsx index 716a712..7beb7c8 100644 --- a/driver-pwa/frontend/src/pages/LoginPage.tsx +++ b/driver-pwa/frontend/src/pages/LoginPage.tsx @@ -30,7 +30,11 @@ export function LoginPage() { setStep("code"); } catch (err: unknown) { const status = (err as { response?: { status?: number } })?.response?.status; - toast.error(status === 404 ? "Номер не найден. Обратитесь в парк." : "Не удалось отправить код"); + const msg = + status === 404 ? "Номер не найден. Обратитесь в парк." : + status === 429 ? "Слишком часто. Попробуйте позже." : + "Не удалось отправить код"; + toast.error(msg); } finally { setBusy(false); }