Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove duplicated Array#to_param #21061

Merged
merged 1 commit into from
Aug 6, 2015

Conversation

yui-knk
Copy link
Contributor

@yui-knk yui-knk commented Jul 29, 2015

Array#to_param is defind in active_support/core_ext/object/to_query.rb,
so we can call to_param if value is_a Array.

@@ -583,8 +583,6 @@ class Generator
PARAMETERIZE = lambda do |name, value|
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

          if name == :controller
            value
          else
            value.to_param
          end

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks I will rewrite it!

`Array#to_param` is defind in active_support/core_ext/object/to_query.rb,
so we can call `to_param` if value is_a Array.
@yui-knk
Copy link
Contributor Author

yui-knk commented Aug 1, 2015

rafaelfranca added a commit that referenced this pull request Aug 6, 2015
Remove duplicated `Array#to_param`
@rafaelfranca rafaelfranca merged commit 1b9ecef into rails:master Aug 6, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants