Merge branch 'develop' of https://gitlab.com/witel-front-end/loan-facilities/user into feature/mohammad_update_form_refactor

This commit is contained in:
2024-01-06 14:20:00 +03:30
4 changed files with 8 additions and 7 deletions

View File

@@ -3,13 +3,14 @@ import process from "next/dist/build/webpack/loaders/resolve-url-loader/lib/post
export const globalServerProps = async ({req, locale}) => {
const {isBot} = parse(req.headers["user-agent"]);
const responseConfig = await fetch(process.env.NEXT_PUBLIC_CONFIG_APP_URL);
const responseConfig = await fetch(`${process.env.NEXT_PUBLIC_CONFIG_APP_URL}?_=${Math.random()}`);
return {
config: await responseConfig.json(),
messages: (await import(`&/locales/${locale}/app.json`)).default,
isBot,
locale,
today: new Date().getTime()
}
}