🚑 Fixes Toon doing I/O in coroutines (#21657)

This commit is contained in:
Franck Nijhof authored and Paulus Schoutsen committed 2019-03-04 15:52:00 -08:00
1 parent 641138a986
commit 73b100d3af
5 files changed
+18 -18

No files matched your search

@@ -102,7 +102,7 @@ class ToonBinarySensor(ToonEntity, BinarySensorDevice):
return value
async def async_update(self) -> None:
def update(self) -> None:
"""Get the latest data from the binary sensor."""
section = getattr(self.toon, self.section)
self._state = getattr(section, self.measurement)