diff options
author | nfnty <git@nfnty.se> | 2017-01-25 14:36:38 +0100 |
---|---|---|
committer | nfnty <git@nfnty.se> | 2017-01-25 14:36:38 +0100 |
commit | 8724cd5e44207e7bc0af77da72b2cd8e1a2fd5c6 (patch) | |
tree | b0ff08ad6351c830010ae866f45aa2bc5317b449 /ranger | |
parent | 7255a023d951c0fa8aa4ee5ed8cbe49852710c97 (diff) | |
download | ranger-8724cd5e44207e7bc0af77da72b2cd8e1a2fd5c6.tar.gz |
container.settings: Do not try to access key before being set
Fixes #446
Diffstat (limited to 'ranger')
-rw-r--r-- | ranger/container/settings.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/ranger/container/settings.py b/ranger/container/settings.py index 4744de4d..f4679453 100644 --- a/ranger/container/settings.py +++ b/ranger/container/settings.py @@ -140,8 +140,7 @@ class Settings(SignalDispatcher, FileManagerAware): signal.value = None elif name == 'use_preview_script': - if self._settings['preview_script'] is None and value \ - and self.fm.ui.is_on: + if self._settings.get('preview_script') is None and value and self.fm.ui.is_on: self.fm.notify("Preview script undefined or not found!", bad=True) |