a guest Apr 16th, 2018 53 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
- ## the routing...
- r.match('/admin').to(:namespace => 'admin') do |a|
- a.resources :users
- a.resources :widgets
- a.resources :gadgets
- a.resource :session
- a.match('/some_misc_thing_for_admins').to(:controller => 'something', :action => 'else')
- ## the results...
- /admin/some_misc_things_for_admins results in Admin::Something#else being dispatched
- /admin/users, /admin/widgets, admin/gadgets, admin/session, result in merb raising Merb::ControllerExceptions::BadRequest
RAW Paste Data