Skip to content

Commit 35a8739

Browse files
author
Peter Saffrey
committed
fix to Go client template to address localVarFile error
1 parent 0da0375 commit 35a8739

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

modules/swagger-codegen/src/main/resources/go/api.mustache

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -148,8 +148,8 @@ func (a *{{{classname}}}Service) {{{nickname}}}(ctx context.Context{{#hasParams}
148148
{{#hasFormParams}}
149149
{{#formParams}}
150150
{{#isFile}}
151-
{{^required}}
152151
var localVarFile {{dataType}}
152+
{^required}}
153153
if localVarOptionals != nil && localVarOptionals.{{vendorExtensions.x-exportParamName}}.IsSet() {
154154
localVarFileOk := false
155155
localVarFile, localVarFileOk = localVarOptionals.{{vendorExtensions.x-exportParamName}}.Value().({{dataType}})

0 commit comments

Comments
 (0)