Strip the verbosity of the debug handler

This commit is contained in:
Asim Aslam 2019-07-28 19:43:50 +01:00 committed by Vasiliy Tolstov
parent 7d6efd8a74
commit a1154590f2
2 changed files with 2 additions and 7 deletions

View File

@ -5,11 +5,6 @@ import (
"github.com/micro/go-micro/server/debug" "github.com/micro/go-micro/server/debug"
) )
// We use this to wrap any debug handlers so we preserve the signature Debug.{Method}
type Debug struct {
debug.DebugHandler
}
func registerDebugHandler(s server.Server) { func registerDebugHandler(s server.Server) {
s.Handle(s.NewHandler(&Debug{s.Options().DebugHandler}, server.InternalHandler(true))) s.Handle(s.NewHandler(&debug.Debug{s.Options().DebugHandler}, server.InternalHandler(true)))
} }

View File

@ -90,7 +90,7 @@ func newOptions(opt ...server.Option) server.Options {
} }
if opts.DebugHandler == nil { if opts.DebugHandler == nil {
opts.DebugHandler = debug.DefaultDebugHandler opts.DebugHandler = debug.DefaultHandler
} }
if len(opts.Address) == 0 { if len(opts.Address) == 0 {