DataSource: Fix openapi spec (#112150)
This commit is contained in:
@@ -201,10 +201,9 @@ func getOpenAPIPostProcessor(version string, builders []APIGroupBuilder, gvs []s
|
||||
keep := make([]map[string]any, 0, len(gvks))
|
||||
for _, val := range gvks {
|
||||
gvk, ok := val.(map[string]any)
|
||||
if ok && gvk["version"] == "__internal" {
|
||||
continue
|
||||
if ok && gvk["group"] == gv.Group && gvk["version"] != "__internal" {
|
||||
keep = append(keep, gvk) // only expose real versions in the same group
|
||||
}
|
||||
keep = append(keep, gvk)
|
||||
}
|
||||
v.Extensions["x-kubernetes-group-version-kind"] = keep
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user