Fix issue where all pages redirect to about when signed out

This commit is contained in:
Darius Kazemi 2022-12-31 11:49:05 -08:00
parent 90350fd418
commit 9a4af5ace4
1 changed files with 3 additions and 1 deletions

View File

@ -163,10 +163,12 @@ class SwitchingColumnsArea extends React.PureComponent {
redirect = <Redirect from='/' to={`/@${initialState.accounts[owner].username}`} exact />;
} else if (showTrends && trendsAsLanding) {
redirect = <Redirect from='/' to='/explore' exact />;
} else {
// Hometown: if signed-out landing page is the about page, don't render the app shell, just redirect
} else if (window.location.pathname === '/' || window.location.pathname === '') {
window.location = '/about';
return null;
} else {
redirect = <Redirect from='/' to='/about' exact />;
}
return (