Skip to content

Commit

Permalink
Fix /users/:username/statuses/:id leading to a soft 404 in web app (m…
Browse files Browse the repository at this point in the history
  • Loading branch information
ClearlyClaire authored Nov 4, 2022
1 parent 4fb0aae commit b8f6f03
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions config/routes.rb
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@
}

get '/users/:username', to: redirect('/@%{username}'), constraints: lambda { |req| req.format.nil? || req.format.html? }
get '/users/:username/statuses/:id', to: redirect('/@%{username}/%{id}'), constraints: lambda { |req| req.format.nil? || req.format.html? }
get '/authorize_follow', to: redirect { |_, request| "/authorize_interaction?#{request.params.to_query}" }

resources :accounts, path: 'users', only: [:show], param: :username do
Expand Down

0 comments on commit b8f6f03

Please sign in to comment.