summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJose M. Guisado <jguisado@soleta.eu>2023-10-18 12:05:23 +0200
committerJose M. Guisado <jguisado@soleta.eu>2023-10-18 12:05:23 +0200
commit59eac6d0d548b0c855d302f86558f94000a83a0d (patch)
tree7c4c2971eaace27bd555694deaab86216b813112
parent39c13287c53bd81d151116b6af434498cf3da0be (diff)
live: hw_inventory: fix typo
Add missing underscore to _bytes_to_human call. Fixes: 39c13287c53bd8 ("live: hw_inventory: fix empty memory bank bug")
-rw-r--r--src/utils/hw_inventory.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/utils/hw_inventory.py b/src/utils/hw_inventory.py
index e7cb463..dff1c7a 100644
--- a/src/utils/hw_inventory.py
+++ b/src/utils/hw_inventory.py
@@ -151,7 +151,7 @@ def _process_core_pci_network(inventory, obj):
def _process_core_pci_storage_child(inventory, obj):
obj_id = obj.get('id', '')
if obj_id.startswith('disk') or obj_id.startswith('nvme'):
- size = bytes_to_human(obj.get('size', 'Unknown size'))
+ size = _bytes_to_human(obj.get('size', 'Unknown size'))
name = ' '.join([obj.get('description', ''), obj.get('product', 'Unknown product'), size])
elem = HardwareElement(HardwareType.DISK, name)
inventory.add_element(elem)