Remove unnecessary TYPE_CHECKING
declarations in SimpliSafe (#65750)
This commit is contained in:
parent
3387e8368b
commit
fbe4d42729
4 changed files with 16 additions and 26 deletions
|
@ -1,8 +1,6 @@
|
|||
"""Support for SimpliSafe alarm control panels."""
|
||||
from __future__ import annotations
|
||||
|
||||
from typing import TYPE_CHECKING
|
||||
|
||||
from simplipy.errors import SimplipyError
|
||||
from simplipy.system import SystemStates
|
||||
from simplipy.system.v3 import SystemV3
|
||||
|
@ -240,8 +238,9 @@ class SimpliSafeAlarm(SimpliSafeEntity, AlarmControlPanelEntity):
|
|||
def async_update_from_websocket_event(self, event: WebsocketEvent) -> None:
|
||||
"""Update the entity when new data comes from the websocket."""
|
||||
self._attr_changed_by = event.changed_by
|
||||
if TYPE_CHECKING:
|
||||
assert event.event_type
|
||||
|
||||
assert event.event_type
|
||||
|
||||
if state := STATE_MAP_FROM_WEBSOCKET_EVENT.get(event.event_type):
|
||||
self._attr_state = state
|
||||
self.async_reset_error_count()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue