Skip to content

Commit

Permalink
Merge pull request #1238 from janpuc/master
Browse files Browse the repository at this point in the history
Fix CreateTunnel for tunnels with config_src
  • Loading branch information
jacobbednarz committed Mar 22, 2023
2 parents e41c0a2 + 74bec24 commit 35a1d3e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
3 changes: 3 additions & 0 deletions .changelog/1238.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:bug
tunnel: Fix 'CreateTunnel' for tunnels using config_src
```
4 changes: 1 addition & 3 deletions tunnel.go
Original file line number Diff line number Diff line change
Expand Up @@ -275,9 +275,7 @@ func (api *API) CreateTunnel(ctx context.Context, rc *ResourceContainer, params

uri := fmt.Sprintf("/accounts/%s/cfd_tunnel", rc.Identifier)

tunnel := Tunnel{Name: params.Name, Secret: params.Secret}

res, err := api.makeRequestContext(ctx, http.MethodPost, uri, tunnel)
res, err := api.makeRequestContext(ctx, http.MethodPost, uri, params)
if err != nil {
return Tunnel{}, err
}
Expand Down

0 comments on commit 35a1d3e

Please sign in to comment.