From b8e2d341f1895e525e52fee95918be05545af4ba Mon Sep 17 00:00:00 2001 From: Dorian Niemiec Date: Mon, 9 Sep 2024 15:57:23 +0200 Subject: [PATCH] fix: remove unused captchaToken state --- components/shared/Newsletter.tsx | 2 -- 1 file changed, 2 deletions(-) diff --git a/components/shared/Newsletter.tsx b/components/shared/Newsletter.tsx index b4d4386..d7e3651 100644 --- a/components/shared/Newsletter.tsx +++ b/components/shared/Newsletter.tsx @@ -19,14 +19,12 @@ const Newsletter = () => { "idle" | "loading" | "success" | "already" | "error" >("idle"); const [input, setInput] = useState(""); - const [captchaToken, setCaptchaToken] = useState(null); const [showCaptcha, setShowCaptcha] = useState(false); const [isSubmitting, setIsSubmitting] = useState(false); // Added this line const buttonRef = useRef(null); const hcaptchaRef = useRef(null); const handleCaptcha = async (token: string) => { - setCaptchaToken(token); setShowCaptcha(false); await handleSubmit(token); };