Use `with_options` for shared settings option in `admin` routes

pull/30847/head
Matt Jankowski 2024-06-26 11:38:16 -04:00
parent 3225954865
commit e6d6666dd3
1 changed files with 4 additions and 2 deletions

View File

@ -40,8 +40,10 @@ namespace :admin do
end
end
get '/settings', to: redirect('/admin/settings/branding')
get '/settings/edit', to: redirect('/admin/settings/branding')
with_options to: redirect('/admin/settings/branding') do
get '/settings'
get '/settings/edit'
end
namespace :settings do
resource :branding, only: [:show, :update], controller: 'branding'