summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--ranger/core/tab.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/ranger/core/tab.py b/ranger/core/tab.py
index 433bfb75..0aca332a 100644
--- a/ranger/core/tab.py
+++ b/ranger/core/tab.py
@@ -80,8 +80,10 @@ class Tab(FileManagerAware, SettingsAware):
 		if self.thisdir:
 			if self.thisdir.marked_items:
 				return self.thisdir.get_selection()
-			else:
+			elif self._thisfile:
 				return [self._thisfile]
+			else:
+				return []
 		return set()
 
 	def assign_cursor_positions_for_subdirs(self):