Module: Roda::RodaPlugins::MultiRun::RequestMethods

Defined in:
lib/roda/plugins/multi_run.rb

Instance Method Summary collapse

Instance Method Details

#multi_runObject

If one of the stored route prefixes match the current request, dispatch the request to the stored rack application.



99
100
101
102
103
104
# File 'lib/roda/plugins/multi_run.rb', line 99

def multi_run
  on self.class.multi_run_regexp do |prefix|
    yield prefix if defined?(yield)
    run scope.class.multi_run_apps[prefix]
  end
end