diff --git a/server/executor.py b/server/executor.py index 2d9121f..138a88b 100644 --- a/server/executor.py +++ b/server/executor.py @@ -84,7 +84,10 @@ class Executor: def removeFileInCurrentDirectory(self, file: str) -> str: file = self.sanitizeFile(file) - currentfile = os.path.join(self.baseDir, self.currentDirectory, file) + if self.currentDirectory == "": + currentfile = os.path.join(self.baseDir, file) + else: + currentfile = os.path.join(self.baseDir, self.currentDirectory, file) if os.path.exists(currentfile): os.remove(currentfile) return currentfile