mirror of
https://github.com/GNS3/gns3-server.git
synced 2026-11-03 05:51:15 +02:00
Fix Error when cleaning image behind us #665
This commit is contained in:
2 files changed
+7
-2
No files matched your search
@@ -512,7 +512,10 @@ class Project:
|
||||
try:
|
||||
pictures = set(os.listdir(self.pictures_directory))
|
||||
for drawing in self._drawings.values():
|
||||
pictures.remove(drawing.ressource_filename)
|
||||
try:
|
||||
pictures.remove(drawing.ressource_filename)
|
||||
except KeyError:
|
||||
pass
|
||||
|
||||
for pict in pictures:
|
||||
os.remove(os.path.join(self.pictures_directory, pict))
|
||||
|
||||
Reference in new issue
Block a user