Explorar o código

Revert "排除客户端中断导致的503错误 (#1343)" (#1351)

This reverts commit 2cdf5e73958149f889630cb57ec7e0879c061aed.
Kevin Wan %!s(int64=3) %!d(string=hai) anos
pai
achega
71d40e0c08
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      rest/handler/loghandler.go

+ 1 - 1
rest/handler/loghandler.go

@@ -185,7 +185,7 @@ func logBrief(r *http.Request, code int, timer *utils.ElapsedTimer, logs *intern
 		buf.WriteString(fmt.Sprintf("\n%s", body))
 	}
 
-	if ok || r.Context().Err() == context.Canceled  {
+	if ok {
 		logger.Info(buf.String())
 	} else {
 		logger.Error(buf.String())