fix add router to context

This commit is contained in:
unknown 2023-08-31 16:40:43 +03:30
parent 1f5302a5f9
commit 13a081c3af

1
box.go
View File

@ -86,6 +86,7 @@ func New(options Options) (*Box, error) {
if err != nil {
return nil, E.Cause(err, "parse route options")
}
ctx = adapter.ContextWithRouter(ctx, router)
inbounds := make([]adapter.Inbound, 0, len(options.Inbounds))
outbounds := make([]adapter.Outbound, 0, len(options.Outbounds))
for i, inboundOptions := range options.Inbounds {