summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Smith <tsmith84@gmail.com>2020-06-06 12:34:19 -0700
committerTim Smith <tsmith84@gmail.com>2020-06-06 12:34:19 -0700
commitc93645b9e1c7e2b96a98762aa58bcb9c8482f55c (patch)
tree5823173125c43ce2126e7a49e6ff2b06dfc5df0f
parentc01c03fba0834bcebb7f90c9c27dd720ab8b4a58 (diff)
downloadohai-blocklist.tar.gz
Remove an internal reference to blacklistblocklist
It's past time for this term to go away, even when it's just the name of a method. Signed-off-by: Tim Smith <tsmith@chef.io>
-rw-r--r--lib/ohai/plugins/kernel.rb15
1 files changed, 8 insertions, 7 deletions
diff --git a/lib/ohai/plugins/kernel.rb b/lib/ohai/plugins/kernel.rb
index 7a1e85e7..7dc273fa 100644
--- a/lib/ohai/plugins/kernel.rb
+++ b/lib/ohai/plugins/kernel.rb
@@ -4,7 +4,7 @@
# Author:: Bryan McLellan (<btm@loftninjas.org>)
# Author:: Claire McQuin (<claire@chef.io>)
# Author:: James Gartrell (<jgartrel@gmail.com>)
-# Copyright:: Copyright (c) 2008-2018 Chef Software, Inc.
+# Copyright:: Copyright (c) Chef Software, Inc.
# Copyright:: Copyright (c) 2009 Bryan McLellan
# License:: Apache License, Version 2.0
#
@@ -137,11 +137,12 @@ Ohai.plugin(:Kernel) do
end
end
- # see if a WMI name is blacklisted so we can avoid writing out
- # useless data to ohai
+ # see if a WMI name is in the blocked list so we can avoid writing
+ # out useless data to ohai
+ #
# @param [String] name the wmi name to check
- # @return [Boolean] is the wmi name blacklisted
- def blacklisted_wmi_name?(name)
+ # @return [Boolean] is the wmi name in the blocked list
+ def blocked_wmi_name?(name)
[
"creation_class_name", # this is just the wmi name
"cs_creation_class_name", # this is just the wmi name
@@ -262,7 +263,7 @@ Ohai.plugin(:Kernel) do
host = wmi.first_of("Win32_OperatingSystem")
kernel[:os_info] = Mash.new
host.wmi_ole_object.properties_.each do |p|
- next if blacklisted_wmi_name?(p.name.wmi_underscore)
+ next if blocked_wmi_name?(p.name.wmi_underscore)
kernel[:os_info][p.name.wmi_underscore.to_sym] = host[p.name.downcase]
end
@@ -277,7 +278,7 @@ Ohai.plugin(:Kernel) do
kernel[:cs_info] = Mash.new
host = wmi.first_of("Win32_ComputerSystem")
host.wmi_ole_object.properties_.each do |p|
- next if blacklisted_wmi_name?(p.name.wmi_underscore)
+ next if blocked_wmi_name?(p.name.wmi_underscore)
kernel[:cs_info][p.name.wmi_underscore.to_sym] = host[p.name.downcase]
end