diff --git a/custom_components/hikvision_axpro/sensor.py b/custom_components/hikvision_axpro/sensor.py index b0f67b7..b1bd598 100644 --- a/custom_components/hikvision_axpro/sensor.py +++ b/custom_components/hikvision_axpro/sensor.py @@ -117,7 +117,7 @@ async def async_setup_entry( devices.append( HikMagnetOpenDetector(coordinator, zone.zone, entry.entry_id) ) - if zone.zone.magnet_shock_current_status.magnet_shock_current_status is not None: + if zone.zone.magnet_shock_current_status.magnet_shock_status is not None: devices.append( HikMagnetShockDetector(coordinator, zone.zone, entry.entry_id) )