[Path] Sanity fixed another bug found in testing

This commit is contained in:
Syres916
2023-09-25 14:18:38 +01:00
committed by GitHub
parent 5cf4626b4d
commit 6309aac3e5

View File

@@ -1202,6 +1202,11 @@ class CommandPathSanity:
if foundSub:
filepath = self.resolveOutputFile(obj)
Path.Log.debug("filepath: {}".format(filepath))
# Make sure the filepath is fully qualified
if os.path.basename(filepath) == filepath:
filepath = f"{os.path.dirname(FreeCAD.ActiveDocument.FileName)}/{filepath}"
Path.Log.debug("filepath: {}".format(filepath))
base_name = os.path.splitext(filepath)[0]
reporthtml = base_name + ".html"
else: