summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorhut <hut@lepus.uberspace.de>2015-10-09 14:43:06 +0200
committerhut <hut@lepus.uberspace.de>2015-10-09 14:43:06 +0200
commit91d784a677604c4bb82db3007c5606a258971acc (patch)
tree95a0d9c6c1d46589acd52b52b5d39e1e46223c3c
parent8d774594cd2006beeff06b65755579b9b46ca44d (diff)
downloadranger-91d784a677604c4bb82db3007c5606a258971acc.tar.gz
core.actions: fixed logic
in reload_cwd, you could reach code that used the variable "cwd" even
though it wasn't defined.  This patch puts this code into an else-block
ensuring that cwd is defined.
-rw-r--r--ranger/core/actions.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/ranger/core/actions.py b/ranger/core/actions.py
index 04932f3f..26dcf4f7 100644
--- a/ranger/core/actions.py
+++ b/ranger/core/actions.py
@@ -134,8 +134,9 @@ class Actions(FileManagerAware, SettingsAware):
             cwd = self.thisdir
         except:
             pass
-        cwd.unload()
-        cwd.load_content()
+        else:
+            cwd.unload()
+            cwd.load_content()
 
     def notify(self, text, duration=4, bad=False):
         """:notify <text>
s. StrictSlash(true). handling POST /api/plain/users for new users' href='/gbmor/getwtxt/commit/main.go?h=v0.2.2&id=d2680fb62bac6c779f371b2b6839592274a8d281'>d2680fb ^
c87acad ^

efa99ed ^
d2680fb ^


efa99ed ^
d6fbc25 ^


efa99ed ^
d2680fb ^


efa99ed ^
5310d08 ^

d2680fb ^


efa99ed ^
5310d08 ^

bd2800a ^
d2680fb ^
5310d08 ^
efa99ed ^
5310d08 ^


d2680fb ^
5310d08 ^
bd2800a ^
efa99ed ^
5310d08 ^
d2680fb ^
dfab6f2 ^
d2680fb ^
d2680fb ^
efa99ed ^
d437b89 ^
d2680fb ^


efa99ed ^
d437b89 ^
dfab6f2 ^
d2680fb ^

fb63b07 ^
bd5e602 ^
bd23ef0 ^
06cffd8 ^
bd23ef0 ^
bd5e602 ^


c87acad ^
747f4fb ^
06cffd8 ^
c87acad ^


893123c ^
bd23ef0 ^
c87acad ^



bd5e602 ^
d083ce6 ^
893123c ^
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90