diff options
author | hut <hut@lepus.uberspace.de> | 2015-01-18 18:50:12 +0100 |
---|---|---|
committer | hut <hut@lepus.uberspace.de> | 2015-01-18 18:50:21 +0100 |
commit | f8a72ee23377d4fdc760aa53e2e08dbf364b5a06 (patch) | |
tree | 7fb1c8c2ccf4ec1336ed015e872d6eac8dec03c4 /ranger | |
parent | 28e7939492280565fbec22e341a1ef6ea798b4c3 (diff) | |
download | ranger-f8a72ee23377d4fdc760aa53e2e08dbf364b5a06.tar.gz |
core.actions: fix linemode validity check
Diffstat (limited to 'ranger')
-rw-r--r-- | ranger/core/actions.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/ranger/core/actions.py b/ranger/core/actions.py index 62092617..d73270d5 100644 --- a/ranger/core/actions.py +++ b/ranger/core/actions.py @@ -164,11 +164,13 @@ class Actions(FileManagerAware, EnvironmentAware, SettingsAware): - "depth" specifies the recursion depth """ - assert mode == "normal" or mode in POSSIBLE_LINEMODES - if mode == "normal": mode = DEFAULT_LINEMODE + if mode not in POSSIBLE_LINEMODES: + self.notify("Unhandled linemode: `%s'" % mode, bad=True) + return + if directory is None: directory = self.fm.thisdir |