refactoring

This commit is contained in:
Maxim Devaev
2023-03-17 23:41:59 +02:00
parent 166cb8e3b7
commit dbb9eda341
3 changed files with 13 additions and 15 deletions

View File

@@ -82,8 +82,8 @@ class Plugin(BaseUserGpioDriver):
await asyncio.sleep(5)
with Inotify() as inotify:
await inotify.watch(os.path.dirname(self.__udc_path), InotifyMask.ALL_MODIFY_EVENTS)
await inotify.watch(self.__profile_path, InotifyMask.ALL_MODIFY_EVENTS)
await inotify.watch(InotifyMask.ALL_MODIFY_EVENTS, os.path.dirname(self.__udc_path))
await inotify.watch(InotifyMask.ALL_MODIFY_EVENTS, self.__profile_path)
self._notifier.notify()
while True:
need_restart = False