Move rubocop exception to code

This commit is contained in:
Luis Ramos
2020-06-22 16:18:27 +01:00
parent 1b5f9f105a
commit 8870dc4b06
2 changed files with 2 additions and 6 deletions

View File

@@ -57,12 +57,6 @@ Lint/UselessAccessModifier:
- 'lib/open_food_network/reports/bulk_coop_report.rb'
- 'spec/lib/open_food_network/reports/report_spec.rb'
# Offense count: 1
# Configuration parameters: CheckForMethodsWithNoSideEffects.
Lint/Void:
Exclude:
- 'app/serializers/api/enterprise_serializer.rb'
# Offense count: 6
# Configuration parameters: IgnoredMethods.
Metrics/AbcSize:

View File

@@ -2,7 +2,9 @@ require 'open_food_network/property_merge'
class Api::EnterpriseSerializer < ActiveModel::Serializer
# We reference this here because otherwise the serializer complains about its absence
# rubocop:disable Lint/Void
Api::IdSerializer
# rubocop:enable Lint/Void
def serializable_hash
cached_serializer_hash.merge uncached_serializer_hash