summary refs log tree commit diff stats
path: root/ranger
diff options
context:
space:
mode:
authortaylorchu <tailinchu@gmail.com>2014-04-05 23:07:25 -0700
committertaylorchu <tailinchu@gmail.com>2014-04-05 23:07:25 -0700
commit95460bf2f76fc83decfc4119f4c8a21c59cbd3b3 (patch)
treeb34e94d804960e1febee66e0694cebf4a5f5fe0e /ranger
parent61390d7b13184d9ae845e2d6bf5b451d0f20a938 (diff)
downloadranger-95460bf2f76fc83decfc4119f4c8a21c59cbd3b3.tar.gz
fix keyerror when updated_preview is called
Diffstat (limited to 'ranger')
-rw-r--r--ranger/container/file.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/ranger/container/file.py b/ranger/container/file.py
index b1245647..f92ffadb 100644
--- a/ranger/container/file.py
+++ b/ranger/container/file.py
@@ -92,4 +92,4 @@ class File(FileSystemObject):
         return self.fm.get_preview(self, width, height)
 
     def is_image_preview(self):
-        return 'imagepreview' in self.fm.previews[self.realpath]
+        return self.realpath in self.fm.previews and 'imagepreview' in self.fm.previews[self.realpath]