summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--ranger/defaults/commands.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/ranger/defaults/commands.py b/ranger/defaults/commands.py
index d3c05023..b874c5fa 100644
--- a/ranger/defaults/commands.py
+++ b/ranger/defaults/commands.py
@@ -73,9 +73,8 @@ class cd(Command):
 
 	def execute(self):
 		line = parse(self.line)
-		try:
-			destination = line.rest(1)
-		except IndexError:
+		destination = line.rest(1)
+		if not destination:
 			destination = '~'
 
 		if destination == '-':
>fac4329 ^
69217dd ^




























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