database manage init

This commit is contained in:
Ruud
2014-02-11 22:19:55 +01:00
parent 8724076601
commit 96e8a909d8
26 changed files with 382 additions and 183 deletions
+3 -3
View File
@@ -47,9 +47,9 @@ class FileManager(Plugin):
for x in file_dict.keys():
files.extend(file_dict[x])
for file in scandir.scandir(cache_dir):
if os.path.splitext(file.name)[1] in ['.png', '.jpg', '.jpeg']:
file_path = os.path.join(cache_dir, file.name)
for f in scandir.scandir(cache_dir):
if os.path.splitext(f.name)[1] in ['.png', '.jpg', '.jpeg']:
file_path = os.path.join(cache_dir, f.name)
if toUnicode(file_path) not in files:
os.remove(file_path)
except: