From fd90b642bf815222e743e217438ae36067f97d54 Mon Sep 17 00:00:00 2001 From: ccd0 Date: Fri, 6 Feb 2015 19:22:16 -0800 Subject: [PATCH] Rewrite gallery condition correctly. --- src/Images/Gallery.coffee | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Images/Gallery.coffee b/src/Images/Gallery.coffee index 8fa22b886..79ecb4db7 100644 --- a/src/Images/Gallery.coffee +++ b/src/Images/Gallery.coffee @@ -79,8 +79,9 @@ Gallery = $.on d, 'keydown', cb.keybinds $.off d, 'keydown', Keybinds.keydown if Conf['Keybinds'] - for file in $$ '.post .file' when !$ '.fileDeletedRes, .fileDeleted', file + for file in $$ '.post .file' post = Get.postFromNode file + continue unless post.file Gallery.generateThumb post # If no image to open is given, pick image we have scrolled to. if !image and Gallery.fullIDs[post.fullID]