nit picking of legacy

This commit is contained in:
6543 2022-11-12 00:08:56 +01:00
parent b759aaf673
commit cba996978e
No known key found for this signature in database
GPG key ID: B8BE6D610E61C862
2 changed files with 2 additions and 4 deletions

View file

@ -2,9 +2,7 @@ package context
import (
stdContext "context"
"io"
"net/http"
"strings"
)
type Context struct {
@ -41,7 +39,7 @@ func (c *Context) String(raw string, status ...int) {
code = status[0]
}
c.RespWriter.WriteHeader(code)
_, _ = io.Copy(c.RespWriter, strings.NewReader(raw))
c.RespWriter.Write([]byte(raw))
}
func (c *Context) IsMethod(m string) bool {