Method: Hanami::Slice::Routing::Middleware::Stack#mapped
- Defined in:
- lib/hanami/slice/routing/middleware/stack.rb
permalink #mapped(builder, prefix, &blk) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
153 154 155 156 157 158 159 |
# File 'lib/hanami/slice/routing/middleware/stack.rb', line 153 def mapped(builder, prefix, &blk) if prefix == ::Hanami::Router::DEFAULT_PREFIX builder.instance_eval(&blk) else builder.map(prefix, &blk) end end |