mirror of
https://github.com/v2ray/v2ray-core.git
synced 2026-11-13 14:44:15 +00:00
generalized event handler
This commit is contained in:
16 files changed
+80
-32
No files matched your search
@@ -52,7 +52,7 @@ func NewCacheServer(ctx context.Context, config *dns.Config) (*CacheServer, erro
|
||||
servers: make([]NameServer, len(config.NameServers)),
|
||||
hosts: config.GetInternalHosts(),
|
||||
}
|
||||
space.OnInitialize(func() error {
|
||||
space.On(app.SpaceInitializing, func(interface{}) error {
|
||||
disp := dispatcher.FromSpace(space)
|
||||
if disp == nil {
|
||||
return newError("dispatcher is not found in the space")
|
||||
|
||||
Reference in new issue
Block a user