From 3820d85e784a09d91c6d220b513933841cd7cf47 Mon Sep 17 00:00:00 2001 From: Achmad Irianto Eka Putra Date: Sat, 21 Dec 2024 12:28:16 +0700 Subject: [PATCH] Refine Drop method comments to clarify error handling. Explain the rationale for not wrapping errors in the Drop method. Emphasize that the returned error is solely for logging and not for further propagation or processing. --- ctx.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ctx.go b/ctx.go index 8facae47de..f51ae38f25 100644 --- a/ctx.go +++ b/ctx.go @@ -1981,6 +1981,6 @@ func (c *DefaultCtx) setRoute(route *Route) { // Drop closes the connection without sending a response. func (c *DefaultCtx) Drop() error { - //nolint:wrapcheck // This must not be wrapped + //nolint:wrapcheck // error wrapping is avoided to keep the operation lightweight and focused on connection closure. return c.RequestCtx().Conn().Close() }