diff options
author | elijah <elijah@riseup.net> | 2014-02-07 00:00:12 -0800 |
---|---|---|
committer | elijah <elijah@riseup.net> | 2014-02-07 00:00:12 -0800 |
commit | e8533d45bf99036952e2465bde0e79faee1dda7c (patch) | |
tree | f4be8588d5794c9315acf9dea023b117a3f43e6b /lib/leap_cli/config/object_list.rb | |
parent | 79afefc5c8a80da51fd735edfcd780c8be5b8ffc (diff) | |
download | leap_cli-e8533d45bf99036952e2465bde0e79faee1dda7c.tar.gz leap_cli-e8533d45bf99036952e2465bde0e79faee1dda7c.tar.bz2 |
added support for custom /etc/hosts files, fixed bug in ObjectList filters (when using negative value on an array attribute).
Diffstat (limited to 'lib/leap_cli/config/object_list.rb')
-rw-r--r-- | lib/leap_cli/config/object_list.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/leap_cli/config/object_list.rb b/lib/leap_cli/config/object_list.rb index 830e96d..9ca4697 100644 --- a/lib/leap_cli/config/object_list.rb +++ b/lib/leap_cli/config/object_list.rb @@ -46,7 +46,9 @@ module LeapCli each do |name, config| value = config[field] if value.is_a? Array - if value.include?(match_value) + if operator == :equal && value.include?(match_value) + results[name] = config + elsif operator == :not_equal && !value.include?(match_value) results[name] = config end else |