Use DeviceInfo in tado (#58603)

Co-authored-by: epenet <epenet@users.noreply.github.com>
This commit is contained in:
epenet 2021-10-28 18:20:09 +02:00 committed by GitHub
parent 6cfa5b2a28
commit e64bc67bec
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -42,14 +42,14 @@ class TadoHomeEntity(Entity):
self.home_id = tado.home_id self.home_id = tado.home_id
@property @property
def device_info(self): def device_info(self) -> DeviceInfo:
"""Return the device_info of the device.""" """Return the device_info of the device."""
return { return DeviceInfo(
"identifiers": {(DOMAIN, self.home_id)}, identifiers={(DOMAIN, self.home_id)},
"name": self.home_name, manufacturer=DEFAULT_NAME,
"manufacturer": DEFAULT_NAME, model=TADO_HOME,
"model": TADO_HOME, name=self.home_name,
} )
class TadoZoneEntity(Entity): class TadoZoneEntity(Entity):