@ -243,7 +243,10 @@ class Post(TimestampMixin, db.Model):
def remove_image_files(self):
for im in self.image_files.values():
os.remove(im)
try:
if im: os.remove(im)
except:
pass
@property
def image_files(self):