Module: Roda::RodaPlugins::EmptyRoot::RequestMethods
- Defined in:
- lib/roda/plugins/empty_root.rb
Instance Method Summary collapse
-
#root(&block) ⇒ Object
Match when the remaining path is the empty string, in addition to the default behavior of matching when the remaining path is
/
.
Instance Method Details
#root(&block) ⇒ Object
Match when the remaining path is the empty string, in addition to the default behavior of matching when the remaining path is /
.
38 39 40 41 42 43 |
# File 'lib/roda/plugins/empty_root.rb', line 38 def root(&block) super if remaining_path.empty? && is_get? always(&block) end end |