Disable Metrics/CyclomaticComplexity for Ability.allowed
There's little point to cut that down.
This commit is contained in:
parent
59413153f5
commit
63477fd27f
|
@ -1,5 +1,6 @@
|
|||
class Ability
|
||||
class << self
|
||||
# rubocop: disable Metrics/CyclomaticComplexity
|
||||
def allowed(user, subject)
|
||||
return anonymous_abilities(user, subject) if user.nil?
|
||||
return [] unless user.is_a?(User)
|
||||
|
|
Loading…
Reference in New Issue