Sha256: f078f8f9131a7e5d5f62fd8b43955cb495f2fd4290d020c718347ffad1d8b498
Contents?: true
Size: 523 Bytes
Versions: 12
Compression:
Stored size: 523 Bytes
Contents
# frozen_string_literal: true module ThemeCheck class Checks < Array def call(method, *args) each do |check| if check.respond_to?(method) && !check.ignored? check.send(method, *args) end end end def always_enabled self.class.new(reject(&:can_disable?)) end def except_for(disabled_checks) still_enabled = reject { |check| disabled_checks.all.include?(check.code_name) } self.class.new((always_enabled + still_enabled).uniq) end end end
Version data entries
12 entries across 12 versions & 1 rubygems