fix add router to context

This commit is contained in:
unknown 2023-08-30 23:56:16 +03:30
parent ab9ee7447a
commit 78837c348c

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 {