From 3693afed59ce3a4cc3eaa4cd3f414c6e55b7ef0a Mon Sep 17 00:00:00 2001 From: Trim21 Date: Mon, 21 Oct 2024 04:54:35 +0800 Subject: [PATCH] chore: fix logging message --- web/error.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/web/error.go b/web/error.go index b144db55..729b4f24 100644 --- a/web/error.go +++ b/web/error.go @@ -80,8 +80,7 @@ func getDefaultErrorHandler() echo.HTTPErrorHandler { if errors.Is(err, context.Canceled) { log.Error("request timeout", - zap.Int("code", http.StatusInternalServerError), - zap.Any("message", "request timeout"), + zap.String("message", err.Error()), zap.String("path", c.Request().URL.Path), zap.String("query", c.Request().URL.RawQuery), zap.String("cf-ray", c.Request().Header.Get(cf.HeaderRequestID)),