Merge branch 'fix/chat-short-path' into 'develop'

fix: force parameter

See merge request witapp/aura-webapp!83
This commit is contained in:
Daniil Chemerkin 2024-04-15 17:09:02 +00:00
commit 0f0301cc3d

View File

@ -139,12 +139,16 @@ function App(): JSX.Element {
const [searchParams] = useSearchParams();
const jwtToken = searchParams.get("token");
const isForce = searchParams.get("force");
if (isForce === "true") {
dispatch(actions.userConfig.addIsForceShortPath(true));
}
if (isForce === "false") {
dispatch(actions.userConfig.addIsForceShortPath(false));
}
useEffect(() => {
if (isForce === "true") {
dispatch(actions.userConfig.addIsForceShortPath(true));
} else {
dispatch(actions.userConfig.addIsForceShortPath(false));
}
// eslint-disable-next-line react-hooks/exhaustive-deps
}, []);
const isForceShortPath = useSelector(selectors.selectIsForceShortPath);
const { gender: genderFromStore } = useSelector(
selectors.selectQuestionnaire