mirror of
https://github.com/v2fly/v2ray-core.git
synced 2026-05-04 19:49:08 -04:00
remove use of any
This commit is contained in:
@@ -5,8 +5,6 @@ package http
|
||||
import (
|
||||
"encoding/json"
|
||||
"errors"
|
||||
|
||||
"v2ray.com/core/proxy/registry"
|
||||
)
|
||||
|
||||
// UnmarshalJSON implements json.Unmarshaler
|
||||
@@ -22,7 +20,3 @@ func (this *ServerConfig) UnmarshalJSON(data []byte) error {
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
func init() {
|
||||
registry.RegisterInboundConfig("http", func() interface{} { return new(ServerConfig) })
|
||||
}
|
||||
|
||||
@@ -13,6 +13,7 @@ import (
|
||||
"v2ray.com/core/app/dispatcher"
|
||||
"v2ray.com/core/common"
|
||||
v2io "v2ray.com/core/common/io"
|
||||
"v2ray.com/core/common/loader"
|
||||
"v2ray.com/core/common/log"
|
||||
v2net "v2ray.com/core/common/net"
|
||||
"v2ray.com/core/proxy"
|
||||
@@ -281,5 +282,5 @@ func (this *ServerFactory) Create(space app.Space, rawConfig interface{}, meta *
|
||||
}
|
||||
|
||||
func init() {
|
||||
registry.MustRegisterInboundHandlerCreator("http", new(ServerFactory))
|
||||
registry.MustRegisterInboundHandlerCreator(loader.GetType(new(ServerConfig)), new(ServerFactory))
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user