diff --git a/canopeum_frontend/.eslintrc.cjs b/canopeum_frontend/.eslintrc.cjs index 312715e76..73d03d6fd 100644 --- a/canopeum_frontend/.eslintrc.cjs +++ b/canopeum_frontend/.eslintrc.cjs @@ -67,11 +67,7 @@ module.exports = { ], ], }, - - - - - ], + ], // Using Bootraps directly without a React wrapper // will cause us to have to add classes to React Components 'react/forbid-component-props': 'off', diff --git a/canopeum_frontend/src/components/Navbar.tsx b/canopeum_frontend/src/components/Navbar.tsx index 64fe649b7..70ba4cf93 100644 --- a/canopeum_frontend/src/components/Navbar.tsx +++ b/canopeum_frontend/src/components/Navbar.tsx @@ -51,7 +51,9 @@ const Navbar = () => { const location = useLocation() const handleChangeLanguage = () => { - const newLanguage = currentLanguage === 'en' ? 'fr' : 'en' + const newLanguage = currentLanguage === 'en' + ? 'fr' + : 'en' setCurrentLanguage(newLanguage) void changeLanguage(newLanguage) } @@ -59,17 +61,14 @@ const Navbar = () => { const { isAuthenticated, logout } = useContext(AuthenticationContext) const navigate = useNavigate() - const onLoginLogoutbuttonClick = (useCallback(() => { + const onLoginLogoutbuttonClick = useCallback(() => { if (isAuthenticated) { logout() } else { navigate(appRoutes.login) } - }, [isAuthenticated, navigate, logout])) + }, [isAuthenticated, navigate, logout]) - - - return (