lib/facter/custom_facts/util/confine.rb in facter-4.5.2 vs lib/facter/custom_facts/util/confine.rb in facter-4.6.0
- old
+ new
@@ -61,10 +61,13 @@
log.debug "Confine raised #{e.class} #{e}"
return false
end
end
- @values.any? { |v| convert(v) === value }
+ # we're intentionally using case equality (triple equals) because we
+ # support matching against anything that supports === such as ranges,
+ # regular expressions, etc
+ @values.any? { |v| convert(v) === value } # rubocop:disable Style/CaseEquality
end
private
def log