From 015fe34820005cfd640540bf5d54be21fa3c2985 Mon Sep 17 00:00:00 2001 From: Shu Guang <61069967+shuguangnet@users.noreply.github.com> Date: Thu, 8 May 2025 23:44:14 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BC=98=E5=8C=96=E7=99=BB=E9=99=86?= =?UTF-8?q?=E5=90=8Ehistory.push=E9=80=BB=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/User/Login/index.tsx | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/pages/User/Login/index.tsx b/src/pages/User/Login/index.tsx index 0236b22..8ad3e92 100644 --- a/src/pages/User/Login/index.tsx +++ b/src/pages/User/Login/index.tsx @@ -97,9 +97,7 @@ useEffect(()=>{ const urlParams = new URL(window.location.href).searchParams; history.push(urlParams.get('redirect') || '/'); sessionStorage.setItem('avatar_refreshed', '1'); - setTimeout(() => { - window.location.reload(); - }, 1000); + window.location.href = urlParams.get('redirect') || '/'; return; } else { message.error(res.message);