From 5f50e424bef9ac216a3df60c6536d2a059ffd1a5 Mon Sep 17 00:00:00 2001 From: what Date: Fri, 2 Jun 2023 14:14:07 +0800 Subject: [PATCH] =?UTF-8?q?[feat]=20Response=20Close=20=E7=9A=84=E6=97=B6?= =?UTF-8?q?=E5=80=99=E9=9C=80=E8=A6=81=20return=20error?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- response.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/response.go b/response.go index c7a4745..338d35e 100644 --- a/response.go +++ b/response.go @@ -43,12 +43,12 @@ func (this Response) Send(data string) error { } // 取消接收数据 -func (this Response) Close() { - this.recv.Close() - +func (this Response) Close() error { if this.method.IsServerStreaming() { this.cancel() } + + return this.recv.Close() } func (this Response) GetCategory() string {