mirror of
https://github.com/labstack/echo.git
synced 2025-01-12 01:22:21 +02:00
Fixed engine.test
Signed-off-by: Vishal Rana <vr@labstack.com>
This commit is contained in:
parent
bbb94b6e79
commit
111d65a5b4
4
echo.go
4
echo.go
@ -292,7 +292,7 @@ func (e *Echo) Debug() bool {
|
|||||||
return e.debug
|
return e.debug
|
||||||
}
|
}
|
||||||
|
|
||||||
// Pre adds middleware to the chain which is runs before router.
|
// Pre adds middleware to the chain which is run before router.
|
||||||
func (e *Echo) Pre(middleware ...Middleware) {
|
func (e *Echo) Pre(middleware ...Middleware) {
|
||||||
e.middleware = append(e.middleware, middleware...)
|
e.middleware = append(e.middleware, middleware...)
|
||||||
e.head = e.pristineHead
|
e.head = e.pristineHead
|
||||||
@ -303,7 +303,7 @@ func (e *Echo) Pre(middleware ...Middleware) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Use adds middleware to the chain which is runs after router.
|
// Use adds middleware to the chain which is run after router.
|
||||||
func (e *Echo) Use(middleware ...Middleware) {
|
func (e *Echo) Use(middleware ...Middleware) {
|
||||||
e.middleware = append(e.middleware, middleware...)
|
e.middleware = append(e.middleware, middleware...)
|
||||||
e.head = e.pristineHead
|
e.head = e.pristineHead
|
||||||
|
@ -24,10 +24,6 @@ func (h *Header) Set(key, val string) {
|
|||||||
h.header.Set(key, val)
|
h.header.Set(key, val)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (h *Header) Object() interface{} {
|
|
||||||
return h.header
|
|
||||||
}
|
|
||||||
|
|
||||||
func (h *Header) reset(hdr http.Header) {
|
func (h *Header) reset(hdr http.Header) {
|
||||||
h.header = hdr
|
h.header = hdr
|
||||||
}
|
}
|
||||||
|
@ -98,10 +98,6 @@ func (r *Request) MultipartForm() (*multipart.Form, error) {
|
|||||||
return m, nil
|
return m, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func (r *Request) Object() interface{} {
|
|
||||||
return r.request
|
|
||||||
}
|
|
||||||
|
|
||||||
func (r *Request) reset(req *http.Request, h engine.Header, u engine.URL) {
|
func (r *Request) reset(req *http.Request, h engine.Header, u engine.URL) {
|
||||||
r.request = req
|
r.request = req
|
||||||
r.header = h
|
r.header = h
|
||||||
|
@ -80,10 +80,6 @@ func (r *Response) Writer() io.Writer {
|
|||||||
return r.writer
|
return r.writer
|
||||||
}
|
}
|
||||||
|
|
||||||
func (r *Response) Object() interface{} {
|
|
||||||
return r.response
|
|
||||||
}
|
|
||||||
|
|
||||||
func (r *Response) reset(w http.ResponseWriter, h engine.Header) {
|
func (r *Response) reset(w http.ResponseWriter, h engine.Header) {
|
||||||
r.response = w
|
r.response = w
|
||||||
r.header = h
|
r.header = h
|
||||||
|
@ -32,10 +32,6 @@ func (u *URL) QueryString() string {
|
|||||||
return u.url.RawQuery
|
return u.url.RawQuery
|
||||||
}
|
}
|
||||||
|
|
||||||
func (u *URL) Object() interface{} {
|
|
||||||
return u.url
|
|
||||||
}
|
|
||||||
|
|
||||||
func (u *URL) reset(url *url.URL) {
|
func (u *URL) reset(url *url.URL) {
|
||||||
u.url = url
|
u.url = url
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user