Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 2 additions & 6 deletions homeassistant/components/homematic/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -797,11 +797,8 @@ def _hm_event_callback(self, device, caller, attribute, value):
has_changed = True

# Availability has changed
if attribute == 'UNREACH':
self._available = not bool(value)
has_changed = True
elif not self.available:
self._available = False
if self.available != (not self._hmdevice.UNREACH):
self._available = not self._hmdevice.UNREACH
has_changed = True

# If it has changed data point, update HASS
Expand All @@ -811,7 +808,6 @@ def _hm_event_callback(self, device, caller, attribute, value):
def _subscribe_homematic_events(self):
"""Subscribe all required events to handle job."""
channels_to_sub = set()
channels_to_sub.add(0) # Add channel 0 for UNREACH

# Push data to channels_to_sub from hmdevice metadata
for metadata in (self._hmdevice.SENSORNODE, self._hmdevice.BINARYNODE,
Expand Down