Skip to content

fix incorrect correct reason element in chkData#86

Merged
djc merged 2 commits intodjc:mainfrom
valkum:fix-chkdata
Feb 20, 2026
Merged

fix incorrect correct reason element in chkData#86
djc merged 2 commits intodjc:mainfrom
valkum:fix-chkdata

Conversation

@valkum
Copy link
Copy Markdown
Contributor

@valkum valkum commented Feb 20, 2026

The schemas for domain, host, and contact mapping are as follows:

<!-- Used as type for <domain:cd> -->
<complexType name="checkType">
  <sequence>
    <element name="name" type="domain:checkNameType"/>
    <element name="reason" type="eppcom:reasonType"
     minOccurs="0"/>
  </sequence>
</complexType>
<!-- Used as type for <host:cd> -->
<complexType name="checkType">
  <sequence>
    <element name="name" type="host:checkNameType"/>
    <element name="reason" type="eppcom:reasonType"
     minOccurs="0"/>
  </sequence>
</complexType>
<!-- Used as type for <contact:cd> -->
<complexType name="checkType">
  <sequence>
    <element name="id" type="contact:checkIDType"/>
    <element name="reason" type="eppcom:reasonType"
     minOccurs="0"/>
  </sequence>
</complexType>

Before this fix, the parser expected the reason to be an attribute.
This fixes this shortcoming and also brings some of the struct names and
field names closer to the schema.

The schemas for domain, host, and contact mapping are as follows:

```
<!-- Used as type for <domain:cd> -->
<complexType name="checkType">
  <sequence>
    <element name="name" type="domain:checkNameType"/>
    <element name="reason" type="eppcom:reasonType"
     minOccurs="0"/>
  </sequence>
</complexType>
```

```
<!-- Used as type for <host:cd> -->
<complexType name="checkType">
  <sequence>
    <element name="name" type="host:checkNameType"/>
    <element name="reason" type="eppcom:reasonType"
     minOccurs="0"/>
  </sequence>
</complexType>
```

```
<!-- Used as type for <contact:cd> -->
<complexType name="checkType">
  <sequence>
    <element name="id" type="contact:checkIDType"/>
    <element name="reason" type="eppcom:reasonType"
     minOccurs="0"/>
  </sequence>
</complexType>
```

Before this fix, the parser expected the reason to be an attribute.
This fixes this shortcoming and also brings some of the struct names and
field names closer to the schema.
This avoids situations where you have to write
`results.list[0].id.id` when contact::CheckData.
Changes all other equivalent structs to be consistent.
@djc djc merged commit fb5e132 into djc:main Feb 20, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants