mirror of
https://github.com/Andre0512/hon.git
synced 2026-05-07 09:54:41 +02:00
Refactor hon entities
This commit is contained in:
@@ -263,12 +263,6 @@ async def async_setup_entry(hass, entry: ConfigEntry, async_add_entities) -> Non
|
||||
class HonBinarySensorEntity(HonEntity, BinarySensorEntity):
|
||||
entity_description: HonBinarySensorEntityDescription
|
||||
|
||||
def __init__(self, hass, entry, device, description) -> None:
|
||||
super().__init__(hass, entry, device)
|
||||
|
||||
self.entity_description = description
|
||||
self._attr_unique_id = f"{super().unique_id}{description.key}"
|
||||
|
||||
@property
|
||||
def is_on(self) -> bool:
|
||||
return (
|
||||
|
||||
Reference in New Issue
Block a user