From 7528e3923fb38e0a2c2f1233b33ff1148f25fda3 Mon Sep 17 00:00:00 2001 From: what Date: Thu, 4 Jul 2024 15:50:56 +0800 Subject: [PATCH] =?UTF-8?q?[feat]=20=E6=B7=BB=E5=8A=A0=20http=20=E5=93=8D?= =?UTF-8?q?=E5=BA=94=E9=94=99=E8=AF=AF=E6=97=A5=E5=BF=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- errno.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/errno.go b/errno.go index cbc7379..35bc296 100644 --- a/errno.go +++ b/errno.go @@ -2,6 +2,7 @@ package contracts import ( "errors" + "log" "github.com/samber/lo" ) @@ -25,6 +26,8 @@ type Err struct { } func (err Err) Error() string { + defer log.Println(err.Code, err.Msg, err.Errord) + return lo.Ternary(err.alert && err.Errord != "", err.Errord, err.Msg) }