From 15d0f22fb7a6b30712d16255cdfd9dbcd1647a2c Mon Sep 17 00:00:00 2001 From: Tony Chen Date: Sat, 22 May 2021 13:46:30 +0800 Subject: [PATCH] fix handler options (#941) --- transport/http/handle.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/transport/http/handle.go b/transport/http/handle.go index b68f0ad02..c70f35f19 100644 --- a/transport/http/handle.go +++ b/transport/http/handle.go @@ -102,6 +102,9 @@ func NewHandler(handler interface{}, opts ...HandleOption) http.Handler { out: typ.Out(0).Elem(), opts: DefaultHandleOptions(), } + for _, o := range opts { + o(&h.opts) + } return h }