fix: Check for direct reference in IsPropertyNodeRequired

This commit is contained in:
Benjamin Nolan (TwoWholeWorms)
2023-01-07 08:53:53 +01:00
committed by Dave Shanley
parent d526584d4f
commit cd63f66efe
2 changed files with 7 additions and 1 deletions

View File

@@ -1721,7 +1721,7 @@ func (index *SpecIndex) extractDefinitionRequiredRefProperties(schemaNode *yaml.
return reqRefProps
}
// If the path we're looking at is a direct ref to another model without any properties, mark it as required, but still continue to look for required properties
// If the node we're looking at is a direct ref to another model without any properties, mark it as required, but still continue to look for required properties
isRef, _, defPath := utils.IsNodeRefValue(schemaNode)
if isRef {
if _, ok := reqRefProps[defPath]; !ok {