Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

additionalProperties attribute in an object with allOf #648

Open
rifkiKargo opened this issue Dec 17, 2024 · 0 comments
Open

additionalProperties attribute in an object with allOf #648

rifkiKargo opened this issue Dec 17, 2024 · 0 comments

Comments

@rifkiKargo
Copy link

rifkiKargo commented Dec 17, 2024

Hi, i have a schema where it looks like this:

UpdateOrderDetail:
      type: object
      additionalProperties: false # Prohibits fields not explicitly listed
      allOf:
        - $ref: "#/components/schemas/BasicOrderDetail"
        - type: object
          properties:
            handlingUnitInfo:
              $ref: '#/components/schemas/BasicHandlingUnitDetail'

I have additionalProperties attribute in the object, where it also has allOf. The current code seems to not care about any attributes in an object if it has allOf, hence the additionalProperties does not seem to work as of now for the above schema. Is there any particular reason on why it works that way? or maybe my schema formatting is actually not common?

Would be great if someone can enlighten me on this one as im trying to start using the lib :D

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

No branches or pull requests

1 participant