fix: show TextPage even if user is not logged in

This commit is contained in:
Maël Gangloff 2024-08-06 17:34:45 +02:00
parent 7f30d446fa
commit c9dc6e58ea
No known key found for this signature in database
GPG Key ID: 11FDC81C24A7F629
2 changed files with 7 additions and 6 deletions

View File

@ -48,7 +48,8 @@ export default function App() {
if (location.pathname === '/login') navigate('/home')
}).catch(() => {
setIsAuthenticated(false)
if (location.pathname !== '/login') navigate('/home')
const pathname = location.pathname
if (!['/login', '/tos', '/faq', '/privacy'].includes(pathname)) navigate('/home')
})
}, []);

View File

@ -539,23 +539,23 @@ msgid ""
"another"
msgstr ""
#: assets/App.tsx:100
#: assets/App.tsx:101
msgid "TOS"
msgstr ""
#: assets/App.tsx:101
#: assets/App.tsx:102
msgid "Privacy Policy"
msgstr ""
#: assets/App.tsx:102
#: assets/App.tsx:103
msgid "FAQ"
msgstr ""
#: assets/App.tsx:104
#: assets/App.tsx:105
msgid "Documentation"
msgstr ""
#: assets/App.tsx:107
#: assets/App.tsx:108
#, javascript-format
msgid ""
"${ ProjectLink } is an open source project distributed under the ${ "