diff --git a/apps/portal/src/components/questions/LandingComponent.tsx b/apps/portal/src/components/questions/LandingComponent.tsx index 4f7837da..2e1795c9 100644 --- a/apps/portal/src/components/questions/LandingComponent.tsx +++ b/apps/portal/src/components/questions/LandingComponent.tsx @@ -42,7 +42,7 @@ export default function LandingComponent({ }; const handleChangeLocation = (newLocation: FilterChoice) => { - setCompany(newLocation); + setLocation(newLocation); }; const handleChangeType = (newQuestionType: QuestionsQuestionType) => { @@ -56,7 +56,7 @@ export default function LandingComponent({ }, [defaultCompany, company]); useEffect(() => { - if (location !== undefined) { + if (location === undefined) { setLocation(defaultLocation); } }, [defaultLocation, location]);