Add and apply Style/ArgumentsForwarding rule
We were using generic names like `args` and `options` which don't really add anything to `*` or `**` because Ruby required us to. That's no longer the case in Ruby 3.2, so we can simplify the code a bit.
This commit is contained in:
@@ -7,13 +7,8 @@ class Admin::Budgets::ActionsComponent < ApplicationComponent
|
||||
|
||||
private
|
||||
|
||||
def action(action_name, **options)
|
||||
render Admin::ActionComponent.new(
|
||||
action_name,
|
||||
budget,
|
||||
"aria-describedby": true,
|
||||
**options
|
||||
)
|
||||
def action(action_name, **)
|
||||
render Admin::ActionComponent.new(action_name, budget, "aria-describedby": true, **)
|
||||
end
|
||||
|
||||
def actions
|
||||
|
||||
@@ -8,8 +8,8 @@ class Admin::Budgets::LinksComponent < ApplicationComponent
|
||||
|
||||
private
|
||||
|
||||
def action(action_name, **options)
|
||||
render Admin::ActionComponent.new(action_name, budget, **options)
|
||||
def action(action_name, **)
|
||||
render Admin::ActionComponent.new(action_name, budget, **)
|
||||
end
|
||||
|
||||
def results_text
|
||||
|
||||
@@ -6,8 +6,8 @@ class Admin::TableActionsComponent < ApplicationComponent
|
||||
@options = options
|
||||
end
|
||||
|
||||
def action(action_name, **args)
|
||||
render Admin::ActionComponent.new(action_name, record, "aria-label": true, **args)
|
||||
def action(action_name, **)
|
||||
render Admin::ActionComponent.new(action_name, record, "aria-label": true, **)
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
Reference in New Issue
Block a user