🎨 Clean up some py2 leftovers & arm more codemods

This commit is contained in:
Gina Häußge committed 2021-02-25 14:17:47 +01:00
1 parent 5b7bc6cb91
commit ca3b78d140
2 files changed
+23 -16

No files matched your search

+1 -2
View File
@@ -43,8 +43,7 @@ class GcodeWatchdogHandler(watchdog.events.PatternMatchingEventHandler):
"""Recursively yield DirEntry objects for given directory."""
for entry in scandir(path):
if entry.is_dir(follow_symlinks=False):
for entry in _recursive_scandir(entry.path):
yield entry
yield from _recursive_scandir(entry.path)
else:
yield entry