From 0eebbf6cb942d1cb329aaa031e1eb0a964893a43 Mon Sep 17 00:00:00 2001 From: mtvpls Date: Sat, 7 Feb 2026 11:50:03 +0800 Subject: [PATCH] =?UTF-8?q?=E7=99=BB=E5=BD=95=E9=A1=B5=E9=9D=A2=E5=A4=84?= =?UTF-8?q?=E7=90=86error=E5=8F=82=E6=95=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/app/login/page.tsx | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/app/login/page.tsx b/src/app/login/page.tsx index 74d629f..5077215 100644 --- a/src/app/login/page.tsx +++ b/src/app/login/page.tsx @@ -85,6 +85,14 @@ function LoginPageClient() { const { siteName } = useSite(); + // 处理URL中的error参数 + useEffect(() => { + const errorParam = searchParams.get('error'); + if (errorParam) { + setError(decodeURIComponent(errorParam)); + } + }, [searchParams]); + // 在客户端挂载后设置配置 useEffect(() => { if (typeof window !== 'undefined') {