summaryrefslogtreecommitdiffstats
path: root/module/database/FileDatabase.py
diff options
context:
space:
mode:
Diffstat (limited to 'module/database/FileDatabase.py')
-rw-r--r--module/database/FileDatabase.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/module/database/FileDatabase.py b/module/database/FileDatabase.py
index abe7c8fc9..116f2b02b 100644
--- a/module/database/FileDatabase.py
+++ b/module/database/FileDatabase.py
@@ -190,8 +190,7 @@ class FileHandler:
self.ev.dispatchEvent("linkDeleted", id, pid)
p = self.getPackage(pid)
- if not len(p.getChildren()):
- p.delete()
+ p.deleteIfEmpty()
pyfiles = self.cache.values()
for pyfile in pyfiles: