summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--ranger/fsobject/fsobject.py6
1 files changed, 1 insertions, 5 deletions
diff --git a/ranger/fsobject/fsobject.py b/ranger/fsobject/fsobject.py
index 963d4472..92ce0d70 100644
--- a/ranger/fsobject/fsobject.py
+++ b/ranger/fsobject/fsobject.py
@@ -274,11 +274,7 @@ class FileSystemObject(MimeTypeAware, FileManagerAware):
 			real_mtime = lstat(self.path).st_mtime
 		except OSError:
 			real_mtime = None
-		if self.stat:
-			cached_mtime = self.stat.st_mtime
-		else:
-			cached_mtime = 0
-		if real_mtime != cached_mtime:
+		if not self.stat or self.stat.st_mtime != real_mtime:
 			self.load()
 			return True
 		return False