diff --git a/frontend/packages/vkt/src/hooks/useKoodistoMunicipalities.ts b/frontend/packages/vkt/src/hooks/useKoodistoMunicipalities.ts index 887accbd7..1a50efa0f 100644 --- a/frontend/packages/vkt/src/hooks/useKoodistoMunicipalities.ts +++ b/frontend/packages/vkt/src/hooks/useKoodistoMunicipalities.ts @@ -18,10 +18,6 @@ const getCodes: () => Array = () => { ); }; -export const useKoodistoMunicipalities = () => { - return getCodes(); -}; - export const useMunicipalityOptions = () => { const translate = useKoodistoMunicipalitiesTranslation(); @@ -30,9 +26,8 @@ export const useMunicipalityOptions = () => { value, label: translate(value), })); - const locale = new Intl.Locale('fi-FI'); - return options.sort((a, b) => a.label.localeCompare(b.label, locale)); + return options.sort((a, b) => a.label.localeCompare(b.label, 'fi-FI')); }, [translate]); return sortedOptions; diff --git a/frontend/packages/vkt/src/tests/msw/handlers.ts b/frontend/packages/vkt/src/tests/msw/handlers.ts index 9b9d1f712..c7c38863c 100644 --- a/frontend/packages/vkt/src/tests/msw/handlers.ts +++ b/frontend/packages/vkt/src/tests/msw/handlers.ts @@ -22,6 +22,8 @@ export const handlers = [ http.get(APIEndpoints.ClerkUser, ({ cookies }) => { const user: ClerkUser = { oid: '1.2.246.562.10.00000000001', + isAdmin: true, + isExaminer: false, }; return new Response(cookies.noAuth ? 'null' : JSON.stringify(user));