Small fixes in SIA (#51401)
* fixes from comment in #51206 * reverted name to async_pull/51454/head
parent
bf3a561149
commit
07d6186fea
|
@ -72,7 +72,7 @@ async def async_setup_entry(
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
class SIAAlarmControlPanel(AlarmControlPanelEntity, SIABaseEntity):
|
class SIAAlarmControlPanel(SIABaseEntity, AlarmControlPanelEntity):
|
||||||
"""Class for SIA Alarm Control Panels."""
|
"""Class for SIA Alarm Control Panels."""
|
||||||
|
|
||||||
def __init__(
|
def __init__(
|
||||||
|
|
|
@ -73,7 +73,7 @@ async def async_setup_entry(
|
||||||
async_add_entities(generate_binary_sensors(entry))
|
async_add_entities(generate_binary_sensors(entry))
|
||||||
|
|
||||||
|
|
||||||
class SIABinarySensorBase(BinarySensorEntity, SIABaseEntity):
|
class SIABinarySensorBase(SIABaseEntity, BinarySensorEntity):
|
||||||
"""Class for SIA Binary Sensors."""
|
"""Class for SIA Binary Sensors."""
|
||||||
|
|
||||||
def __init__(
|
def __init__(
|
||||||
|
|
|
@ -81,7 +81,8 @@ class SIABaseEntity(RestoreEntity):
|
||||||
if self._cancel_availability_cb:
|
if self._cancel_availability_cb:
|
||||||
self._cancel_availability_cb()
|
self._cancel_availability_cb()
|
||||||
|
|
||||||
async def async_handle_event(self, sia_event: SIAEvent) -> None:
|
@callback
|
||||||
|
def async_handle_event(self, sia_event: SIAEvent) -> None:
|
||||||
"""Listen to dispatcher events for this port and account and update state and attributes.
|
"""Listen to dispatcher events for this port and account and update state and attributes.
|
||||||
|
|
||||||
If the port and account combo receives any message it means it is online and can therefore be set to available.
|
If the port and account combo receives any message it means it is online and can therefore be set to available.
|
||||||
|
|
Loading…
Reference in New Issue