Use k8s schema to determine formatting if no type on setter

This commit is contained in:
Morten Torkildsen
2020-07-31 13:44:47 -07:00
parent feeaa994b7
commit 5c433ead5e
5 changed files with 26 additions and 15 deletions

View File

@@ -97,7 +97,7 @@ func (a *Add) visitMapping(object *yaml.RNode, p string, _ *openapi.ResourceSche
// visitScalar implements visitor
// visitScalar will set the field metadata on each scalar field whose name + value match
func (a *Add) visitScalar(object *yaml.RNode, p string, _ *openapi.ResourceSchema) error {
func (a *Add) visitScalar(object *yaml.RNode, p string, _, _ *openapi.ResourceSchema) error {
// check if the field matches
if a.Type == "array" {
return nil