-
-
Save maasha/69aaee9255496ebfdae6 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def exact_match_key_values?(record, keys) | |
keys.each do |key| | |
return true if @exact.include?(key) | |
if (value = record[key]) | |
return true if value.is_a?(String) && @exact.include?(value.to_sym) | |
return true if !value.is_a?(String) && @exact.include?(value) | |
end | |
end | |
false | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment