Skip to content

Commit

Permalink
include ctx parameters in WSDL template outputs
Browse files Browse the repository at this point in the history
  • Loading branch information
Grant Gongaware committed Feb 1, 2019
1 parent 199b101 commit 38f8dbf
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions header_tmpl.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions operations_tmpl.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,9 @@ var opsTmpl = `
{{$requestType := findType .Input.Message | replaceReservedWords | makePublic}}
{{$soapAction := findSOAPAction .Name $privateType}}
{{$responseType := findType .Output.Message | replaceReservedWords | makePublic}}
func (service *{{$privateType}}) {{makePublic .Name | replaceReservedWords}} ({{if ne $requestType ""}}request *{{$requestType}}{{end}}) (*{{$responseType}}, error) {
func (service *{{$privateType}}) {{makePublic .Name | replaceReservedWords}} (ctx context.Context, {{if ne $requestType ""}}request *{{$requestType}}{{end}}) (*{{$responseType}}, error) {
response := new({{$responseType}})
err := service.client.Call("{{$soapAction}}", {{if ne $requestType ""}}request{{else}}nil{{end}}, response)
err := service.client.Call(ctx, "{{$soapAction}}", {{if ne $requestType ""}}request{{else}}nil{{end}}, response)
if err != nil {
return nil, err
}
Expand Down

0 comments on commit 38f8dbf

Please sign in to comment.