module Roda::RodaPlugins::PathRewriter::RequestMethods

  1. lib/roda/plugins/path_rewriter.rb

Methods

Public Class

  1. new

Public Class methods

new(scope, env)

Rewrite remaining_path and/or PATH_INFO based on the path rewrites.

[show source]
   # File lib/roda/plugins/path_rewriter.rb
88 def initialize(scope, env)
89   path_info = env['PATH_INFO']
90 
91   rewrite_path(scope.class.path_info_rewrites, path_info)
92   super
93   remaining_path = @remaining_path = @remaining_path.dup
94   rewrite_path(scope.class.remaining_path_rewrites, remaining_path)
95 end