mirror of
https://github.com/home-assistant/core.git
synced 2025-07-14 00:37:13 +00:00
Fix update of surveillance_station data in Synology DSM (#47966)
This commit is contained in:
parent
9fd6980144
commit
949cd4714a
@ -441,12 +441,11 @@ class SynoApi:
|
|||||||
)
|
)
|
||||||
return
|
return
|
||||||
|
|
||||||
|
# surveillance_station is updated by own coordinator
|
||||||
|
self.dsm.reset(self.surveillance_station)
|
||||||
|
|
||||||
# Determine if we should fetch an API
|
# Determine if we should fetch an API
|
||||||
self._with_system = bool(self.dsm.apis.get(SynoCoreSystem.API_KEY))
|
self._with_system = bool(self.dsm.apis.get(SynoCoreSystem.API_KEY))
|
||||||
self._with_surveillance_station = bool(
|
|
||||||
self.dsm.apis.get(SynoSurveillanceStation.CAMERA_API_KEY)
|
|
||||||
) or bool(self.dsm.apis.get(SynoSurveillanceStation.HOME_MODE_API_KEY))
|
|
||||||
|
|
||||||
self._with_security = bool(
|
self._with_security = bool(
|
||||||
self._fetching_entities.get(SynoCoreSecurity.API_KEY)
|
self._fetching_entities.get(SynoCoreSecurity.API_KEY)
|
||||||
)
|
)
|
||||||
@ -497,14 +496,6 @@ class SynoApi:
|
|||||||
self.dsm.reset(self.utilisation)
|
self.dsm.reset(self.utilisation)
|
||||||
self.utilisation = None
|
self.utilisation = None
|
||||||
|
|
||||||
if not self._with_surveillance_station:
|
|
||||||
_LOGGER.debug(
|
|
||||||
"Disable surveillance_station api from being updated for '%s'",
|
|
||||||
self._entry.unique_id,
|
|
||||||
)
|
|
||||||
self.dsm.reset(self.surveillance_station)
|
|
||||||
self.surveillance_station = None
|
|
||||||
|
|
||||||
def _fetch_device_configuration(self):
|
def _fetch_device_configuration(self):
|
||||||
"""Fetch initial device config."""
|
"""Fetch initial device config."""
|
||||||
self.information = self.dsm.information
|
self.information = self.dsm.information
|
||||||
|
Loading…
x
Reference in New Issue
Block a user