mirror of https://github.com/gin-gonic/gin.git
Revert "Merge pull request #753 from gin-gonic/bug"
This reverts commit556287ff08
, reversing changes made to32cab500ec
.
This commit is contained in:
parent
556287ff08
commit
63b5d1c4c8
|
@ -8,7 +8,6 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"io"
|
"io"
|
||||||
"os"
|
"os"
|
||||||
"runtime"
|
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"golang.org/x/crypto/ssh/terminal"
|
"golang.org/x/crypto/ssh/terminal"
|
||||||
|
@ -49,11 +48,8 @@ func Logger() HandlerFunc {
|
||||||
// Example: os.Stdout, a file opened in write mode, a socket...
|
// Example: os.Stdout, a file opened in write mode, a socket...
|
||||||
func LoggerWithWriter(out io.Writer, notlogged ...string) HandlerFunc {
|
func LoggerWithWriter(out io.Writer, notlogged ...string) HandlerFunc {
|
||||||
isTerm := true
|
isTerm := true
|
||||||
|
if outFile, ok := out.(*os.File); ok {
|
||||||
if runtime.GOOS != "appengine" && runtime.GOOS != "netbsd" && runtime.GOOS != "openbsd" {
|
isTerm = terminal.IsTerminal(int(outFile.Fd()))
|
||||||
if outFile, ok := out.(*os.File); ok {
|
|
||||||
isTerm = terminal.IsTerminal(int(outFile.Fd()))
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
var skip map[string]struct{}
|
var skip map[string]struct{}
|
||||||
|
|
Loading…
Reference in New Issue