17143 removed pref from myportal page rely on link for lang

This commit is contained in:
2025-06-18 12:49:38 +01:00
parent 806952b98d
commit a92b0af2db
2 changed files with 15 additions and 10 deletions
+8 -8
View File
@@ -231,14 +231,14 @@ export const getServerSideProps = wrapper.getServerSideProps(
const pathWithoutLocale = ctx.resolvedUrl.replace(/^\/(cy|en)/, "");
//console.log("==============================", pathWithoutLocale);
if (preferredLocale !== locale) {
return {
redirect: {
destination: `/${preferredLocale}${pathWithoutLocale}`,
permanent: false,
},
};
}
// if (preferredLocale !== locale) {
// return {
// redirect: {
// destination: `/${preferredLocale}${pathWithoutLocale}`,
// permanent: false,
// },
// };
// }
const showLoginCheck = Boolean(process.env.SHOWLOGIN);
const showReps = Boolean(process.env.SHOWREPRESENTATIONS);