This commit is contained in:
bryanqiu 2022-11-07 17:28:31 +08:00
parent 52b4d750d1
commit 997627c1b8

6
log.go
View File

@ -31,8 +31,8 @@ const ErrLogPanic = "~~~~panic~~~~~~"
//////////////global log//////////////////begin///////////////////
func PrintPreety(prefix string, v interface{}) {
mylogger.PrintPreety(prefix, v)
func PrintPretty(prefix string, v interface{}) {
mylogger.PrintPretty(prefix, v)
}
func DebugfWithDepth(calldepth int, format string, v ...interface{}) {
mylogger.DebugfWithDepth(calldepth, format, v...)
@ -81,7 +81,7 @@ func (log *Logger) Print(prefix string, v interface{}) {
preety, _ := json.Marshal(v)
log.logwrite("DEBUGE", 3, prefix+"%s\n", preety)
}
func (log *Logger) PrintPreety(prefix string, v interface{}) {
func (log *Logger) PrintPretty(prefix string, v interface{}) {
preety, _ := json.MarshalIndent(v, "==", " ")
log.logwrite("DEBUGE", 3, prefix+"%s\n", preety)
}