summary refs log tree commit diff stats
path: root/ranger/core/actions.py
diff options
context:
space:
mode:
Diffstat (limited to 'ranger/core/actions.py')
-rw-r--r--ranger/core/actions.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/ranger/core/actions.py b/ranger/core/actions.py
index c85b7313..3c9f6135 100644
--- a/ranger/core/actions.py
+++ b/ranger/core/actions.py
@@ -140,7 +140,10 @@ class Actions(FileManagerAware, EnvironmentAware, SettingsAware):
 
 	def move_parent(self, n):
 		parent = self.env.at_level(-1)
-		self.env.enter_dir(parent.files[parent.pointer+n])
+		try:
+			self.env.enter_dir(parent.files[parent.pointer+n])
+		except IndexError:
+			pass
 
 	def history_go(self, relative):
 		"""Move back and forth in the history"""
='#n22'>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