Skip to content

Commit 1715e52

Browse files
authored
tools/openapi2crd: use only required fields from plugin chain (#3007)
1 parent e54bfd0 commit 1715e52

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

tools/openapi2crd/pkg/plugins/read_write_properties.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,7 @@ func (p *ReadWriteProperties) Process(req *PropertyProcessorRequest) error {
3838
return nil
3939
}
4040

41-
required := sets.New(req.OpenAPISchema.Required...)
42-
required.Insert(req.Property.Required...)
41+
required := sets.New(req.Property.Required...)
4342
for name, prop := range req.OpenAPISchema.Properties {
4443
if prop.Value.ReadOnly {
4544
required.Delete(name)

0 commit comments

Comments
 (0)