Compare commits

...

2 Commits

Author SHA1 Message Date
Matt Jankowski
b3fa873ae6
Merge 6e970ba6fd into 94bceb8683 2025-07-11 14:05:42 +00:00
Matt Jankowski
6e970ba6fd Disable Metrics/* cops 2025-07-03 18:26:14 -04:00
3 changed files with 13 additions and 23 deletions

View File

@ -1,17 +1,21 @@
---
Metrics/AbcSize:
Exclude:
- lib/mastodon/cli/*.rb
Enabled: false
Metrics/BlockLength:
Enabled: false
Metrics/BlockNesting:
Enabled: false
Metrics/ClassLength:
Enabled: false
Metrics/CollectionLiteralLength:
Enabled: false
Metrics/CyclomaticComplexity:
Exclude:
- lib/mastodon/cli/*.rb
Enabled: false
Metrics/MethodLength:
Enabled: false
@ -20,4 +24,7 @@ Metrics/ModuleLength:
Enabled: false
Metrics/ParameterLists:
CountKeywordArgs: false
Enabled: false
Metrics/PerceivedComplexity:
Enabled: false

View File

@ -10,23 +10,6 @@ Lint/NonLocalExitFromIterator:
Exclude:
- 'app/helpers/json_ld_helper.rb'
# Configuration parameters: AllowedMethods, AllowedPatterns, CountRepeatedAttributes.
Metrics/AbcSize:
Max: 82
# Configuration parameters: CountBlocks, CountModifierForms, Max.
Metrics/BlockNesting:
Exclude:
- 'lib/tasks/mastodon.rake'
# Configuration parameters: AllowedMethods, AllowedPatterns.
Metrics/CyclomaticComplexity:
Max: 25
# Configuration parameters: AllowedMethods, AllowedPatterns.
Metrics/PerceivedComplexity:
Max: 27
# This cop supports safe autocorrection (--autocorrect).
# Configuration parameters: AllowedVars, DefaultToNil.
Style/FetchEnvVar:

View File

@ -12,7 +12,7 @@ class InitialStateSerializer < ActiveModel::Serializer
has_one :push_subscription, serializer: REST::WebPushSubscriptionSerializer
has_one :role, serializer: REST::RoleSerializer
def meta # rubocop:disable Metrics/AbcSize
def meta
store = default_meta_store
if object.current_account