Merge "Handle absent manufacturer field correctly"
This commit is contained in:
commit
b0ee75ca91
4
agent
4
agent
|
@ -1049,10 +1049,10 @@ class NodeAgent
|
||||||
def _manufacturer
|
def _manufacturer
|
||||||
if _is_virtualbox
|
if _is_virtualbox
|
||||||
@facter['productname']
|
@facter['productname']
|
||||||
elsif (@facter['manufacturer'].upcase != 'QEMU' && @facter['is_virtual'])
|
elsif (@facter.fetch('manufacturer', '').upcase != 'QEMU' && @facter['is_virtual'])
|
||||||
@facter['virtual']
|
@facter['virtual']
|
||||||
else
|
else
|
||||||
@facter['manufacturer']
|
@facter.fetch('manufacturer', '')
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue