Skip to content

Commit

Permalink
chore(martian): ignore nestif in if p.ConnectPassthrough
Browse files Browse the repository at this point in the history
This commit should be reverted when #445 is fixed.
  • Loading branch information
mmatczuk committed Sep 27, 2023
1 parent 719bd2c commit 4b403a3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion internal/martian/handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ func (p proxyHandler) handleConnectRequest(ctx *Context, rw http.ResponseWriter,
cw io.WriteCloser
cerr error
)
if p.ConnectPassthrough {
if p.ConnectPassthrough { //nolint:nestif // to be fixed in #445
pr, pw := io.Pipe()
req.Body = pr
defer req.Body.Close()
Expand Down
2 changes: 1 addition & 1 deletion internal/martian/proxy.go
Original file line number Diff line number Diff line change
Expand Up @@ -507,7 +507,7 @@ func (p *Proxy) handleConnectRequest(ctx *Context, req *http.Request, session *S
cw io.WriteCloser
cerr error
)
if p.ConnectPassthrough {
if p.ConnectPassthrough { //nolint:nestif // to be fixed in #445
pr, pw := io.Pipe()
req.Body = pr
defer req.Body.Close()
Expand Down

0 comments on commit 4b403a3

Please sign in to comment.