mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
85f95b2f58
`helper_method` was taking `**kwargs` on all definitions by default. ruby will assume that this means you want keyword args and call `to_hash` on what you pass if the object responds to `to_hash`. Instead we should only take keyword args if the helper method defined intends to pass keyword args. This also fixes a warning when you pass a hash to your helper method, ``` warning: Using the last argument as keyword parameters is deprecated; maybe ** should be added to the call ``` Also, this would be a good candidate for using `...`, but since `send` requires the method as the first argument, we can't use it here. |
||
---|---|---|
.. | ||
abstract_controller | ||
action_controller | ||
action_dispatch | ||
action_pack | ||
abstract_controller.rb | ||
action_controller.rb | ||
action_dispatch.rb | ||
action_pack.rb |