Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

board.delete_post: Check if there's an image before deleting

  • Loading branch information...
commit 77b7a6cd10b499a9b7abeb0b730c9cc622b18469 1 parent 46ac95a
@dequis authored
Showing with 2 additions and 1 deletion.
  1. +2 −1  board.py
View
3  board.py
@@ -726,7 +726,8 @@ def delete_post(self, post, password, file_only, archiving, from_window):
images_to_baleet = session.execute(select_thread_images)
for i in images_to_baleet:
- self.delete_file(i.image, i.thumbnail)
+ if i.image and i.thumbnail:
+ self.delete_file(i.image, i.thumbnail)
delete_query = table.delete(or_(
table.c.num == post,
Please sign in to comment.
Something went wrong with that request. Please try again.