aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/lib
diff options
context:
space:
mode:
authorAaron Patterson <aaron.patterson@gmail.com>2014-05-23 15:25:34 -0700
committerAaron Patterson <aaron.patterson@gmail.com>2014-05-23 15:25:46 -0700
commit6d48d979471818f8302233c1738afae1f030eea5 (patch)
tree5f45df646a4a643030d288637137f55395b85ac2 /actionpack/lib
parent7abde1360b863f34900474ad70d1b41e50944ea3 (diff)
downloadrails-6d48d979471818f8302233c1738afae1f030eea5.tar.gz
rails-6d48d979471818f8302233c1738afae1f030eea5.tar.bz2
rails-6d48d979471818f8302233c1738afae1f030eea5.zip
glob_param is never used, so rm
this also changes the constructor. We don't need to pass more options than "defaults" (whatever defaults are, ugh. probably another hash of stupid stuff).
Diffstat (limited to 'actionpack/lib')
-rw-r--r--actionpack/lib/action_dispatch/routing/mapper.rb2
-rw-r--r--actionpack/lib/action_dispatch/routing/route_set.rb10
2 files changed, 3 insertions, 9 deletions
diff --git a/actionpack/lib/action_dispatch/routing/mapper.rb b/actionpack/lib/action_dispatch/routing/mapper.rb
index 7e78b417fa..0870d3779c 100644
--- a/actionpack/lib/action_dispatch/routing/mapper.rb
+++ b/actionpack/lib/action_dispatch/routing/mapper.rb
@@ -301,7 +301,7 @@ module ActionDispatch
end
def dispatcher
- Routing::RouteSet::Dispatcher.new(:defaults => defaults)
+ Routing::RouteSet::Dispatcher.new(defaults)
end
def to
diff --git a/actionpack/lib/action_dispatch/routing/route_set.rb b/actionpack/lib/action_dispatch/routing/route_set.rb
index e9fb712a61..40c767e685 100644
--- a/actionpack/lib/action_dispatch/routing/route_set.rb
+++ b/actionpack/lib/action_dispatch/routing/route_set.rb
@@ -21,9 +21,8 @@ module ActionDispatch
PARAMETERS_KEY = 'action_dispatch.request.path_parameters'
class Dispatcher #:nodoc:
- def initialize(options={})
- @defaults = options[:defaults]
- @glob_param = options.delete(:glob)
+ def initialize(defaults)
+ @defaults = defaults
@controller_class_names = ThreadSafe::Cache.new
end
@@ -53,7 +52,6 @@ module ActionDispatch
def prepare_params!(params)
normalize_controller!(params)
merge_default_action!(params)
- split_glob_param!(params) if @glob_param
end
# If this is a default_controller (i.e. a controller specified by the user)
@@ -89,10 +87,6 @@ module ActionDispatch
def merge_default_action!(params)
params[:action] ||= 'index'
end
-
- def split_glob_param!(params)
- params[@glob_param] = params[@glob_param].split('/').map { |v| URI.parser.unescape(v) }
- end
end
# A NamedRouteCollection instance is a collection of named routes, and also