From 111568d746d5c8eedddfd76aafece318c1ffc605 Mon Sep 17 00:00:00 2001 From: javayhu Date: Mon, 30 Jun 2025 23:05:38 +0800 Subject: [PATCH] fix: show captcha when turnstile is enabled only --- src/components/auth/register-form.tsx | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/components/auth/register-form.tsx b/src/components/auth/register-form.tsx index 21c0f77..c6a6600 100644 --- a/src/components/auth/register-form.tsx +++ b/src/components/auth/register-form.tsx @@ -230,10 +230,12 @@ export const RegisterForm = ({ - form.setValue('captchaToken', token)} - validationError={form.formState.errors.captchaToken?.message} - /> + {turnstileEnabled && ( + form.setValue('captchaToken', token)} + validationError={form.formState.errors.captchaToken?.message} + /> + )}