Skip to content

Commit

Permalink
build(CLI): Fix broken API template (#486)
Browse files Browse the repository at this point in the history
  • Loading branch information
jablan authored Dec 13, 2023
1 parent d407d8b commit d5b2dff
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions openapi-generator/templates/cli/api.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -67,11 +67,11 @@ func init{{{nickname}}}() {
{{else~}}
if params.IsSet(helpers.ToSnakeCase("{{paramName}}")) {
var {{paramName}} map[string]interface{}
if err := json.Unmarshal([]byte(params.GetString(helpers.ToSnakeCase("{{{vendorExtensions.x-export-param-name}}}"))),
&{{paramName}}); err != nil {
if err := json.Unmarshal([]byte(params.GetString(helpers.ToSnakeCase("{{{vendorExtensions.x-export-param-name}}}"))), &{{paramName}}); err != nil {
HandleError(err)
}
localVarOptionals.{{{vendorExtensions.x-export-param-name}}} = optional.NewInterface({{paramName}})
}
localVarOptionals.{{{vendorExtensions.x-export-param-name}}} = optional.NewInterface({{paramName}})
{{/isModel~}}
{{/isPrimitiveType~}}
{{else~}}
Expand Down

0 comments on commit d5b2dff

Please sign in to comment.