summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorhut <hut@hut.pm>2017-07-07 12:54:41 +0200
committerhut <hut@hut.pm>2017-07-07 12:54:41 +0200
commit5e644ae68ebba7abbc8aa92266e7f8b9e8d97a8a (patch)
tree4ef069416ad9e83ec83655bcfbf8204187c45d14
parentc46b6770b66edc77169da3a399f093f9ec81ab62 (diff)
downloadranger-5e644ae68ebba7abbc8aa92266e7f8b9e8d97a8a.tar.gz
core.fm: more efficient preview cache cleaning
-rw-r--r--ranger/core/fm.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/ranger/core/fm.py b/ranger/core/fm.py
index 9f409a94..76aa7876 100644
--- a/ranger/core/fm.py
+++ b/ranger/core/fm.py
@@ -106,7 +106,7 @@ class FM(Actions,  # pylint: disable=too-many-instance-attributes
 
         self.settings.signal_bind(
             'setopt.preview_images',
-            lambda signal: setattr(signal.fm, 'previews', {}),
+            lambda signal: signal.fm.previews.clear(),
         )
 
         if ranger.args.clean: