Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revert "fix(#188): add headers from original request to redirects" #190

Closed
wants to merge 2 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 0 additions & 9 deletions internal/websocket/ws.go
Original file line number Diff line number Diff line change
Expand Up @@ -411,15 +411,6 @@ func (ws *Websocket) newHTTPClient(mode ipMode) (*http.Client, error) {
return nil, err
}

// update client redirect to send all headers on subsequent requests
client.CheckRedirect = func(req *http.Request, via []*http.Request) error {
// Copy headers from the first request to original requests
for key, value := range via[0].Header {
req.Header[key] = value
}
return nil
}

// Override config.NewClient()'s Transport and update it's DialContext with the provided mode.
transport, err := config.Transport.NewTransport(config.TLS)
if err != nil {
Expand Down
Loading