explicitly nav to /home #homehack

This commit is contained in:
robcolbert 2019-07-03 19:29:54 -04:00
parent 54fe77650d
commit fb49559d05
5 changed files with 6 additions and 7 deletions

View File

@ -11,7 +11,7 @@ export default class ColumnBackButton extends React.PureComponent {
handleClick = () => { handleClick = () => {
if (window.history && window.history.length === 1) { if (window.history && window.history.length === 1) {
this.context.router.history.push('/'); this.context.router.history.push('/home'); // homehack
} else { } else {
this.context.router.history.goBack(); this.context.router.history.goBack();
} }

View File

@ -34,7 +34,7 @@ class ColumnHeader extends React.PureComponent {
historyBack = () => { historyBack = () => {
if (window.history && window.history.length === 1) { if (window.history && window.history.length === 1) {
this.context.router.history.push('/'); this.context.router.history.push('/home'); // homehack
} else { } else {
this.context.router.history.goBack(); this.context.router.history.goBack();
} }

View File

@ -33,7 +33,7 @@ export default class ErrorBoundary extends React.PureComponent {
<div className='error-boundary'> <div className='error-boundary'>
<div> <div>
<FormattedMessage id='alert.unexpected.message' defaultMessage='Error' /> <FormattedMessage id='alert.unexpected.message' defaultMessage='Error' />
<a href='/'>Return Home</a> <a href='/home'>Return Home</a>
</div> </div>
</div> </div>
); );

View File

@ -182,7 +182,7 @@ class SwitchingColumnsArea extends React.PureComponent {
return ( return (
<Switch> <Switch>
{/* <Redirect from='/' to='/home' exact /> */} <Redirect from='/' to='/home' exact />
<WrappedRoute path='/home' exact layout={LAYOUT.HOME} component={HomeTimeline} content={children} /> <WrappedRoute path='/home' exact layout={LAYOUT.HOME} component={HomeTimeline} content={children} />
<WrappedRoute path='/groups' component={Groups} content={children} /> <WrappedRoute path='/groups' component={Groups} content={children} />
@ -444,7 +444,7 @@ class UI extends React.PureComponent {
handleHotkeyBack = () => { handleHotkeyBack = () => {
if (window.history && window.history.length === 1) { if (window.history && window.history.length === 1) {
this.context.router.history.push('/'); this.context.router.history.push('/home'); // homehack
} else { } else {
this.context.router.history.goBack(); this.context.router.history.goBack();
} }

View File

@ -24,7 +24,6 @@ Rails.application.routes.draw do
get '.well-known/change-password', to: redirect('/auth/edit') get '.well-known/change-password', to: redirect('/auth/edit')
get '.well-known/keybase-proof-config', to: 'well_known/keybase_proof_config#show' get '.well-known/keybase-proof-config', to: 'well_known/keybase_proof_config#show'
get '/src/gab-social.zip', to: 'downloads#source'
get 'manifest', to: 'manifests#show', defaults: { format: 'json' } get 'manifest', to: 'manifests#show', defaults: { format: 'json' }
get 'intent', to: 'intents#show' get 'intent', to: 'intents#show'
get 'custom.css', to: 'custom_css#show', as: :custom_css get 'custom.css', to: 'custom_css#show', as: :custom_css
@ -138,7 +137,7 @@ Rails.application.routes.draw do
resources :filters, except: [:show] resources :filters, except: [:show]
resource :relationships, only: [:show, :update] resource :relationships, only: [:show, :update]
get '/public', to: redirect('/'), as: :public_timeline get '/public', to: redirect('/home'), as: :public_timeline # homehack
get '/media_proxy/:id/(*any)', to: 'media_proxy#show', as: :media_proxy get '/media_proxy/:id/(*any)', to: 'media_proxy#show', as: :media_proxy
# Remote follow # Remote follow