When defining the routes, the order depended on the order of keys in an object.
Sometimes this meant that the /resource_name/:id route was ahead of /resource_name/new which ensured that when visiting /resource_name/new the request would get mapped to the "show" action with an :id param of 'new'.
When defining the routes, the order depended on the order of keys in an object.
Sometimes this meant that the
/resource_name/:id
route was ahead of/resource_name/new
which ensured that when visiting/resource_name/new
the request would get mapped to the "show" action with an :id param of 'new'.I simply defined the order of routes.