Skip to content
Browse files

`recall` should be `path_parameters`, also make it required

"recall" is a terrible name.  This variable contains the parameters that
we got from the path (e.g. for "/posts/1" it has :controller => "posts",
:id => "1").  Since it contains the parameters we got from the path,
"path_parameters" is a better name.  We always pass path_parameters to
`generate`, so lets make it required.
  • Loading branch information...
1 parent 212057b commit 932386be8a9c0f60c7bb078261c5433aeccb3284 @tenderlove tenderlove committed Jul 17, 2014
Showing with 3 additions and 3 deletions.
  1. +3 −3 actionpack/lib/action_dispatch/journey/formatter.rb
6 actionpack/lib/action_dispatch/journey/formatter.rb
@@ -12,12 +12,12 @@ def initialize(routes)
@cache = nil
- def generate(name, options, recall = {}, parameterize = nil)
- constraints = recall.merge(options)
+ def generate(name, options, path_parameters, parameterize = nil)
+ constraints = path_parameters.merge(options)
missing_keys = []
match_route(name, constraints) do |route|
- parameterized_parts = extract_parameterized_parts(route, options, recall, parameterize)
+ parameterized_parts = extract_parameterized_parts(route, options, path_parameters, parameterize)
# Skip this route unless a name has been provided or it is a
# standard Rails route since we can't determine whether an options

0 comments on commit 932386b

Please sign in to comment.
Something went wrong with that request. Please try again.