This commit is contained in:
hailin 2025-04-22 20:27:21 +08:00
parent d353f68354
commit a1acfccba5
4 changed files with 4 additions and 1 deletions

View File

@ -38,7 +38,7 @@ export default function ChangePasswordPage() {
console.log("...........[login page.tsx]")
router.push(`${homePath}/login`) router.push(`${homePath}/login`)
// router.push(`${locale}/login`) // router.push(`${locale}/login`)
} else { } else {

View File

@ -96,6 +96,7 @@ export default function SetupPage() {
if (!session) { if (!session) {
// 强制跳转到带有 locale 的 login 页面 // 强制跳转到带有 locale 的 login 页面
console.log("...........[setup/page.tsx]")
return router.push(`${homePath}/login`) return router.push(`${homePath}/login`)
// return router.push(`/${locale}/login`) // return router.push(`/${locale}/login`)
} else { } else {

View File

@ -92,6 +92,7 @@ export function LanguageSwitcher() {
startTransition(() => { startTransition(() => {
if (pathname !== newPath) { if (pathname !== newPath) {
console.log("...........[language-switcher]...]")
router.push(newPath) router.push(newPath)
} else { } else {
router.refresh() router.refresh()

View File

@ -198,6 +198,7 @@ export const ProfileSettings: FC<ProfileSettingsProps> = ({}) => {
locale = segment locale = segment
} }
const homePath = locale === defaultLocale ? "/" : `/${locale}` const homePath = locale === defaultLocale ? "/" : `/${locale}`
console.log("...........[profile-setting.tsx]")
router.push(homePath) router.push(homePath)
router.refresh() router.refresh()
return return