xmlclass/xsdschema.py
changeset 1849 6811021e3d94
parent 1847 6198190bc121
child 1852 70c1cc354a8f
--- a/xmlclass/xsdschema.py	Thu Oct 05 16:41:31 2017 +0300
+++ b/xmlclass/xsdschema.py	Thu Oct 05 16:46:29 2017 +0300
@@ -784,7 +784,7 @@
     annotations, children = factory.ReduceElements(elements)
 
     for child in children:
-        if children["maxOccurs"] == "unbounded" or children["maxOccurs"] > 1:
+        if child["maxOccurs"] == "unbounded" or child["maxOccurs"] > 1:
             raise ValueError("\"all\" item can't have \"maxOccurs\" attribute greater than 1!")
 
     return {"type": "all", "elements": children, "minOccurs": attributes["minOccurs"],