lib/rubocop/cop/style/special_global_vars.rb in rubocop-1.50.2 vs lib/rubocop/cop/style/special_global_vars.rb in rubocop-1.51.0
- old
+ new
@@ -232,12 +232,12 @@
vars[global]
end
def matching_styles(global)
- STYLE_VARS_MAP.map do |style, vars|
+ STYLE_VARS_MAP.filter_map do |style, vars|
style if vars.values.flatten(1).include? global
- end.compact
+ end
end
def english_name_replacement(preferred_name, node)
return "\#{#{preferred_name}}" if node.begin_type?