ESPHome fix missing state in certain circumstances (#28729)
* Fix ESPHome having missing state in certain situations Fixes https://github.com/esphome/issues/issues/828 * Update requirements_all * Also fix climate preset mode
This commit is contained in:
1 parent
fc04b3e31c
commit
a1f2b6d402
6 files changed
+10
-4
No files matched your search
@@ -44,6 +44,8 @@ class EsphomeBinarySensor(EsphomeEntity, BinarySensorDevice):
|
||||
return self._entry_data.available
|
||||
if self._state is None:
|
||||
return None
|
||||
if self._state.missing_state:
|
||||
return None
|
||||
return self._state.state
|
||||
|
||||
@property
|
||||
|
||||
Reference in new issue
Block a user