This commit is contained in:
Cayo Puigdefabregas 2022-12-05 09:58:12 +01:00
parent 94a586f00b
commit e3f01f4795
1 changed files with 2 additions and 3 deletions

View File

@ -748,9 +748,9 @@ class Device(Thing):
def set_hid(self): def set_hid(self):
""" """
# product_vendor, is a manufacturer # product_vendor, is a manufacturer
# product_family, is a model but from dmidecode # product_family, is a new field of lshw
# product_chassis, is a type of chassis # product_chassis, is a type of chassis
# product_number, is a ?? # product_number, is a model
# product_version, # product_version,
# product_sku, # product_sku,
# product_serial, is a serial number # product_serial, is a serial number
@ -763,7 +763,6 @@ class Device(Thing):
with suppress(TypeError): with suppress(TypeError):
family = (self.family or '').replace(' ', '_') family = (self.family or '').replace(' ', '_')
model = ((self.model or '').replace(' ', '_'),) model = ((self.model or '').replace(' ', '_'),)
model = model or family
chassis = self.type chassis = self.type
if hasattr(self, 'chassis'): if hasattr(self, 'chassis'):
chassis = self.chassis and self.chassis.name or '' chassis = self.chassis and self.chassis.name or ''