Define __init__ before other methods in La Marzocco (#187553)

Co-authored-by: Claude <noreply@anthropic.com>
This commit is contained in:
Joost Lekkerkerker
2026-10-20 18:00:47 +02:00
committed by GitHub
co-authored by Claude
parent 6541d25bf5
commit f8d05b602a
+11 -11
View File
@@ -102,6 +102,17 @@ class LaMarzoccoEntity(LaMarzoccoBaseEntity):
entity_description: LaMarzoccoEntityDescription
def __init__(
self,
coordinator: LaMarzoccoUpdateCoordinator,
entity_description: LaMarzoccoEntityDescription,
bluetooth_coordinator: LaMarzoccoBluetoothUpdateCoordinator | None = None,
) -> None:
"""Initialize the entity."""
super().__init__(coordinator, entity_description.key)
self.entity_description = entity_description
self.bluetooth_coordinator = bluetooth_coordinator
@property
@override
def available(self) -> bool:
@@ -120,17 +131,6 @@ class LaMarzoccoEntity(LaMarzoccoBaseEntity):
return self.entity_description.available_fn(self.coordinator)
return False
def __init__(
self,
coordinator: LaMarzoccoUpdateCoordinator,
entity_description: LaMarzoccoEntityDescription,
bluetooth_coordinator: LaMarzoccoBluetoothUpdateCoordinator | None = None,
) -> None:
"""Initialize the entity."""
super().__init__(coordinator, entity_description.key)
self.entity_description = entity_description
self.bluetooth_coordinator = bluetooth_coordinator
@override
async def async_added_to_hass(self) -> None:
"""Handle when entity is added to hass."""