diff --git a/src/Mod/Path/PathScripts/PathDressupHoldingTags.py b/src/Mod/Path/PathScripts/PathDressupHoldingTags.py index 098d6f75fc..66e84961c2 100644 --- a/src/Mod/Path/PathScripts/PathDressupHoldingTags.py +++ b/src/Mod/Path/PathScripts/PathDressupHoldingTags.py @@ -134,11 +134,10 @@ class Tag: self.height = math.fabs(height) self.actualHeight = self.height self.angle = math.fabs(angle) - self.radius = ( - radius - if FreeCAD.Units.Quantity == type(radius) - else FreeCAD.Units.Quantity(radius, FreeCAD.Units.Length) - ) + if hasattr(radius, "Value"): + self.radius = radius.Value + else: + self.radius = FreeCAD.Units.Quantity(radius, FreeCAD.Units.Length).Value self.enabled = enabled self.isSquare = False @@ -209,7 +208,7 @@ class Tag: self.solid.translate(orig) radius = min(self.radius, radius) self.realRadius = radius - if not PathGeom.isRoughly(0, radius.Value): + if not PathGeom.isRoughly(0, radius): PathLog.debug("makeFillet(%.4f)" % radius) self.solid = self.solid.makeFillet(radius, [self.solid.Edges[0]])