mirror of
https://github.com/StuffAnThings/qbit_manage.git
synced 2025-11-10 08:20:49 +08:00
fix for remove orphan to not remove root dir
This commit is contained in:
parent
2df0bf441d
commit
1000f90567
1 changed files with 2 additions and 2 deletions
|
|
@ -161,7 +161,7 @@ def remove_empty_directories(pathlib_root_dir):
|
|||
# list all directories recursively and sort them by path,
|
||||
# longest first
|
||||
L = sorted(
|
||||
pathlib_root_dir.glob("**"),
|
||||
pathlib_root_dir.glob("*/*"),
|
||||
key=lambda p: len(str(p)),
|
||||
reverse=True,
|
||||
)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue