fix hijack logger middleware

Signed-off-by: Emile Vauge <emile@vauge.com>
This commit is contained in:
Emile Vauge 2016-05-12 16:32:12 +02:00
parent 749b381f26
commit cb0c1d34a2
No known key found for this signature in database
GPG key ID: D808B4C167352E59

View file

@ -1,6 +1,7 @@
package middlewares
import (
"bufio"
"fmt"
log "github.com/Sirupsen/logrus"
"github.com/streamrail/concurrent-map"
@ -167,6 +168,10 @@ func (lirw *logInfoResponseWriter) Flush() {
}
}
func (lirw *logInfoResponseWriter) Hijack() (net.Conn, *bufio.ReadWriter, error) {
return lirw.rw.(http.Hijacker).Hijack()
}
func (lirw *logInfoResponseWriter) GetStatus() int {
return lirw.status
}