Skip to content

Commit

Permalink
Merge pull request #51 from gjohansson-ST/isonline_error
Browse files Browse the repository at this point in the history
Fix isonline error
  • Loading branch information
gjohansson-ST authored Mar 12, 2022
2 parents c789498 + de361da commit b9f9575
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions custom_components/sector/coordinator.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
from .const import API_URL, LOGGER


class SectorAlarmHub(object):
class SectorAlarmHub:
"""Sector connectivity hub."""

def __init__(
Expand Down Expand Up @@ -191,10 +191,9 @@ async def fetch_info(self, tempcheck: bool = True) -> None:
)
if response:
json_data = await response.json()
if json_data["IsOnline"] is True:
self._alarmstatus = json_data["Status"]
LOGGER.debug("self._alarmstatus = %s", self._alarmstatus)
LOGGER.debug("Full output panelstatus: %s", json_data)
self._alarmstatus = json_data["Status"]
LOGGER.debug("self._alarmstatus = %s", self._alarmstatus)
LOGGER.debug("Full output panelstatus: %s", json_data)

if self._temps and self._sector_temp and self._update_sensors:
response = await self._request(
Expand Down

0 comments on commit b9f9575

Please sign in to comment.