gin-gonic/gin — pull request #11 by alexandernyquist (2014-07-01 07:24:01+00:00)
Title: Setting response headers before calling WriteHeader.

As documented in the ResponseWriter type:

Header returns the header map that will be sent by WriteHeader.
Changing the header after a call to WriteHeader (or Write) has
no effect.