Sha256: 13cf85cea10da535e05a0bceb262a74e929b79f220a0acc3814655f8e6c97b7d
Contents?: true
Size: 577 Bytes
Versions: 6867
Compression:
Stored size: 577 Bytes
Contents
# frozen_string_literal: true module RuboCop module Cop # Handles `Max` configuration parameters, especially setting them to an # appropriate value with --auto-gen-config. module ConfigurableMax private def max=(value) cfg = config_to_allow_offenses cfg[:exclude_limit] ||= {} current_max = cfg[:exclude_limit][max_parameter_name] value = [current_max, value].max if current_max cfg[:exclude_limit][max_parameter_name] = value end def max_parameter_name 'Max' end end end end
Version data entries
6,867 entries across 6,841 versions & 29 rubygems