Open luweimy opened 6 years ago
because one header could have multiple values.
Just calling Add would keep the previous value, and add another value to the header.
On Tue, Nov 21, 2017 at 6:23 AM, luwei notifications@github.com wrote:
func copyHeaders(dst, src http.Header) { for k, := range dst { dst.Del(k) } for k, vs := range src { for , v := range vs { dst.Add(k, v) } } }
I write cookie to response in middleware, but goproxy will remove response harders
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/elazarl/goproxy/issues/259, or mute the thread https://github.com/notifications/unsubscribe-auth/AAP4os6f1BtEKRFJcTttR4A-XhLchLsqks5s4lAogaJpZM4QlQ8y .
I write cookie to response in middleware, but goproxy will remove response headers. What should I do?.