diff --git a/src/versions/solarfm-0.0.1/SolarFM/solarfm/shellfm/windows/view/Path.py b/src/versions/solarfm-0.0.1/SolarFM/solarfm/shellfm/windows/view/Path.py index 7c4cdc2..69a492a 100644 --- a/src/versions/solarfm-0.0.1/SolarFM/solarfm/shellfm/windows/view/Path.py +++ b/src/versions/solarfm-0.0.1/SolarFM/solarfm/shellfm/windows/view/Path.py @@ -11,7 +11,10 @@ class Path: return os.path.expanduser("~") + self.subpath def get_path(self): - return "/" + "/".join(self.path) + if self.path: + return f"/{'/'.join(self.path)}" + else: + return f"/{''.join(self.path)}" def get_path_list(self): return self.path @@ -21,14 +24,14 @@ class Path: self.load_directory() def pop_from_path(self): - if len(self.path) > 1: + if self.path: self.path.pop() if not self.go_past_home: if self.get_home() not in self.get_path(): self.set_to_home() - self.load_directory() + self.load_directory() def set_path(self, path): if path == self.get_path(): diff --git a/src/versions/solarfm-0.0.1/SolarFM/solarfm/signal_classes/mixins/WidgetFileActionMixin.py b/src/versions/solarfm-0.0.1/SolarFM/solarfm/signal_classes/mixins/WidgetFileActionMixin.py index 06ba422..85a947c 100644 --- a/src/versions/solarfm-0.0.1/SolarFM/solarfm/signal_classes/mixins/WidgetFileActionMixin.py +++ b/src/versions/solarfm-0.0.1/SolarFM/solarfm/signal_classes/mixins/WidgetFileActionMixin.py @@ -232,7 +232,10 @@ class WidgetFileActionMixin: target = f"{view.get_current_directory()}" if file_name: - path = f"{target}/{file_name}" + if len(target) == 1: + path = f"{target}{file_name}" + else: + path = f"{target}/{file_name}" if type == True: # Create File self.handle_files([path], "create_file")