BUG: lambdaurl.Wrap
does not add Content-Type
or Content-Length
headers like http.ResponseWriter
does
#508
Labels
lambdaurl.Wrap
does not add Content-Type
or Content-Length
headers like http.ResponseWriter
does
#508
The
http.ResponseWriter
implementation says the following thing about Content-Type header (and it actually has a note about Content-Length too).As of right now the
lambdaurl.Wrap
implementation completely misses this and causes all content without an explicit Content-Type header to get it withapplication/json
. Which is different and incorrect when compared to how thehttp.Handler
normally works.A simple repro for this is to use
http.FileServer
with e.g. HTML files. The HTML files will not be loaded by the browser properly as the response will haveContent-Type: application/json
header in it but when running the same handler normally it will work fine.The text was updated successfully, but these errors were encountered: