Fix lint error (#7757)
This commit is contained in:
parent
2b97340133
commit
1094d66659
|
@ -888,10 +888,10 @@ func (mod *modContext) genNestedTypes(member interface{}, resourceType bool) []d
|
|||
// the provided slice of properties in the schema.
|
||||
func (mod *modContext) getProperties(properties []*schema.Property, lang string, input, nested, isProvider bool,
|
||||
) []property {
|
||||
return mod.getPropertiesWithIdPrefixAndExclude(properties, lang, input, nested, isProvider, "", nil)
|
||||
return mod.getPropertiesWithIDPrefixAndExclude(properties, lang, input, nested, isProvider, "", nil)
|
||||
}
|
||||
|
||||
func (mod *modContext) getPropertiesWithIdPrefixAndExclude(properties []*schema.Property, lang string, input, nested,
|
||||
func (mod *modContext) getPropertiesWithIDPrefixAndExclude(properties []*schema.Property, lang string, input, nested,
|
||||
isProvider bool, idPrefix string, exclude func(name string) bool) []property {
|
||||
if len(properties) == 0 {
|
||||
return nil
|
||||
|
|
|
@ -70,14 +70,14 @@ func (mod *modContext) genMethod(r *schema.Resource, m *schema.Method) methodDoc
|
|||
exclude := func(name string) bool {
|
||||
return name == "__self__"
|
||||
}
|
||||
props := mod.getPropertiesWithIdPrefixAndExclude(f.Inputs.Properties, lang, true, false, false,
|
||||
props := mod.getPropertiesWithIDPrefixAndExclude(f.Inputs.Properties, lang, true, false, false,
|
||||
fmt.Sprintf("%s_arg_", m.Name), exclude)
|
||||
if len(props) > 0 {
|
||||
inputProps[lang] = props
|
||||
}
|
||||
}
|
||||
if f.Outputs != nil {
|
||||
outputProps[lang] = mod.getPropertiesWithIdPrefixAndExclude(f.Outputs.Properties, lang, false, false, false,
|
||||
outputProps[lang] = mod.getPropertiesWithIDPrefixAndExclude(f.Outputs.Properties, lang, false, false, false,
|
||||
fmt.Sprintf("%s_result_", m.Name), nil)
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue