simplified AioNotifier()

This commit is contained in:
Maxim Devaev
2022-08-07 19:04:32 +03:00
parent aa630988cc
commit ec9785b4be
18 changed files with 43 additions and 54 deletions

View File

@@ -135,7 +135,7 @@ class Plugin(BaseUserGpioDriver): # pylint: disable=too-many-instance-attribute
await self.__update_power()
new = (self.__online, self.__power)
if new != prev:
await self._notifier.notify()
self._notifier.notify()
prev = new
await asyncio.sleep(self.__state_poll)