lib/rubocop/cop/cop.rb in rubocop-0.38.0 vs lib/rubocop/cop/cop.rb in rubocop-0.39.0

- old
+ new

@@ -136,22 +136,21 @@ @options[:debug] end def display_cop_names? debug? || @options[:display_cop_names] || - config['AllCops'] && config['AllCops']['DisplayCopNames'] + @config.for_all_cops['DisplayCopNames'] end def display_style_guide? (style_guide_url || reference_url) && (@options[:display_style_guide] || - config['AllCops'] && config['AllCops']['DisplayStyleGuide']) + config.for_all_cops['DisplayStyleGuide']) end def extra_details? - @options[:extra_details] || - config['AllCops'] && config['AllCops']['ExtraDetails'] + @options[:extra_details] || config.for_all_cops['ExtraDetails'] end def message(_node = nil) self.class::MSG end @@ -192,10 +191,10 @@ Formatter::DisabledConfigFormatter.config_to_allow_offenses[cop_name] = hash end def target_ruby_version - @config['AllCops'] && @config['AllCops']['TargetRubyVersion'] + @config.for_all_cops['TargetRubyVersion'] end def parse(source, path = nil) ProcessedSource.new(source, target_ruby_version, path) end