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

Tiny refactoring in NumberHelper and RecordTagHelper #6002

Merged
merged 2 commits into from Apr 26, 2012
Merged

Conversation

lest
Copy link
Contributor

@lest lest commented Apr 26, 2012

  • use safe_join in number helper
  • refactor content_tag_for helper:
    • do not use merge! just for 2 values
    • there is no need to check block arity

- do not use merge! just for 2 values
- there is no need to check block arity
@sikachu
Copy link
Member

sikachu commented Apr 26, 2012

I'm not sure if removing arity check is a good idea though. If people somehow calling content_tag_for without a receiving variable it will raises an exception.

@lest
Copy link
Contributor Author

lest commented Apr 26, 2012

@sikachu It should not raise an exception because block is not a lambda and doesn't check argument count

jeremy added a commit that referenced this pull request Apr 26, 2012
Tiny refactoring in NumberHelper and RecordTagHelper
@jeremy jeremy merged commit 8b0489c into rails:master Apr 26, 2012
@rafaelfranca
Copy link
Member

👍

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

5 participants