not able to specify params placeholder in 2nd nesting level for namespacesΒ #1353
Closed
Description
Hey,
I've noticed a strange behavior in 2.0.0 with nested namespaces, that used to work in 1.4.x.
It seems that using /:foo
placeholder is only possible up to the first level of nesting for namespace paths.
I have created a minimal example showcasing this issue at: https://github.com/foxxx0/sinatra-2.0-namespace-nesting-issue
which boils down to:
# nesting namespaces seems to work just fine...
namespace '/working' do
namespace '/:id' do
# this works just fine
get { params.inspect }
end
end
# ... until it doesn't
namespace '/broken' do
namespace '/foo' do
namespace '/:id' do
# for some reason this triggers Sinatra::NotFound, resulting in a 404
get { params.inspect }
end
end
end
I was not able to find anything related in the 2.0.0 changelog, so I'm not sure if this intended behavior or a bug.
Cheers,
Thore
Metadata
Assignees
Labels
No labels