Commit 28b7a11e authored by Antoine Catton's avatar Antoine Catton

Use generator instead of comprehensive list.

parent 8909da3f
...@@ -46,7 +46,7 @@ def wait_for_creation(filepath): ...@@ -46,7 +46,7 @@ def wait_for_creation(filepath):
else: else:
while True: while True:
events = inotifyx.get_events(creation_fd) events = inotifyx.get_events(creation_fd)
if filename in [e.name for e in events]: if filename in (e.name for e in events):
break break
finally: finally:
os.close(creation_fd) os.close(creation_fd)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment