1
0
mirror of https://github.com/astaxie/beego.git synced 2024-11-25 21:11:29 +00:00

Don't rewrite content-type

This commit is contained in:
Amine KABAB 2016-12-14 17:19:31 +00:00
parent 90999717dd
commit 8fac2d8d58

View File

@ -185,7 +185,11 @@ func (c *Controller) Render() error {
if err != nil { if err != nil {
return err return err
} }
if c.Ctx.ResponseWriter.Header().Get("Content-Type") == "" {
c.Ctx.Output.Header("Content-Type", "text/html; charset=utf-8") c.Ctx.Output.Header("Content-Type", "text/html; charset=utf-8")
}
return c.Ctx.Output.Body(rb) return c.Ctx.Output.Body(rb)
} }