|
@@ -4,6 +4,7 @@ import (
|
|
|
"github.com/gin-gonic/gin"
|
|
|
"runtime/debug"
|
|
|
"slices"
|
|
|
+ "strconv"
|
|
|
"time"
|
|
|
)
|
|
|
|
|
@@ -18,10 +19,9 @@ func GinLogger(skipPaths []string) gin.HandlerFunc {
|
|
|
}
|
|
|
|
|
|
end := time.Now()
|
|
|
- Info(" %d | %d | %s | %s \"%s\"",
|
|
|
+ Info(" %d | %s | %s \"%s\"",
|
|
|
c.Writer.Status(),
|
|
|
- end.Sub(start),
|
|
|
- c.ClientIP(),
|
|
|
+ strconv.Itoa(int(end.Sub(start).Milliseconds()))+"ms",
|
|
|
c.Request.Method,
|
|
|
path,
|
|
|
)
|