Skip to content

Commit

Permalink
rubocop -a
Browse files Browse the repository at this point in the history
Fixes two cases of Rails/Delegate, which are now caught thanks to
an enhancement in rubocop-rails 2.30.0.

See https://github.com/rubocop/rubocop-rails/releases/tag/v2.30.0
  • Loading branch information
sandbergja committed Feb 20, 2025
1 parent cf4500c commit be50a3c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
4 changes: 1 addition & 3 deletions app/components/blacklight/document/action_component.rb
Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,7 @@ def url
end
end

def key
@action.key
end
delegate :key, to: :@action
end
end
end
4 changes: 1 addition & 3 deletions app/presenters/blacklight/json_presenter.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,7 @@ def initialize(response, blacklight_config)

delegate :facet_field_names, :facet_configuration_for_field, to: :blacklight_config

def documents
@response.documents
end
delegate :documents, to: :@response

# @return [Array<Blacklight::Solr::Response::Facets::FacetField>]
def search_facets
Expand Down

0 comments on commit be50a3c

Please sign in to comment.