Merge pull request #3715 from ryanbugden/main

Allow axisOrdering to be set to zero
This commit is contained in:
Just van Rossum 2024-12-03 22:03:42 +01:00 committed by GitHub
commit 332602ebc4
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1596,7 +1596,7 @@ class BaseDocWriter(object):
mapElement.attrib["input"] = self.intOrFloat(inputValue)
mapElement.attrib["output"] = self.intOrFloat(outputValue)
axisElement.append(mapElement)
if axisObject.axisOrdering or axisObject.axisLabels:
if axisObject.axisOrdering is not None or axisObject.axisLabels:
labelsElement = ET.Element("labels")
if axisObject.axisOrdering is not None:
labelsElement.attrib["ordering"] = str(axisObject.axisOrdering)