Explorar o código

Use Writer in Context.Status (#1606)

willnewrelic %!s(int64=6) %!d(string=hai) anos
pai
achega
0ce4661029
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      context.go

+ 1 - 1
context.go

@@ -744,7 +744,7 @@ func bodyAllowedForStatus(status int) bool {
 
 // Status sets the HTTP response code.
 func (c *Context) Status(code int) {
-	c.writermem.WriteHeader(code)
+	c.Writer.WriteHeader(code)
 }
 
 // Header is a intelligent shortcut for c.Writer.Header().Set(key, value).