Skip to content

Commit 47b8786

Browse files
committed
fix(hardware categorization): trim ' Inc.' from the manufacturer
The manufacturer sometimes includes ' Inc.' and sometimes not, so let's just trim that to make things consistent.
1 parent d960cfc commit 47b8786

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

python/ironic-understack/ironic_understack/resource_class.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,9 @@ def __call__(self, task, inventory, plugin_data):
4545
cpu_cores = inventory.get("cpu", {}).get("count", 0)
4646
manufacturer = inventory.get("system_vendor", {}).get("manufacturer", "")
4747

48+
# trim ' Inc.'
49+
manufacturer = manufacturer.replace(" Inc.", "")
50+
4851
machine = Machine(
4952
memory_mb=memory_mb,
5053
cpu=cpu_model_name,

0 commit comments

Comments
 (0)