Skip to content

Commit

Permalink
Merge pull request #33 from EOSIO/3947-cleos-issue
Browse files Browse the repository at this point in the history
Fix issue in EOSIO/eos#3947
  • Loading branch information
ericiles authored Jun 8, 2018
2 parents 5325aa4 + 029a766 commit e193089
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions filter.go
Original file line number Diff line number Diff line change
Expand Up @@ -288,10 +288,6 @@ func chainMiddleware(mw ...middleware) middleware {

func copyHeaders(response http.Header, request http.Header) {
for key, value := range request {
// Let our server set the Content-Length
if key == "Content-Length" {
continue
}
for _, header := range value {
response.Add(key, header)
}
Expand All @@ -314,6 +310,10 @@ func forwardCallToNodeos(w http.ResponseWriter, r *http.Request) {
return
}

// Forward headers to nodeos
request.Header = make(http.Header)
copyHeaders(request.Header, r.Header)

res, err := client.Do(request)

if err != nil {
Expand Down

0 comments on commit e193089

Please sign in to comment.