diff --git a/core/core.go b/core/core.go index 825cac8..d3cc812 100644 --- a/core/core.go +++ b/core/core.go @@ -16,7 +16,7 @@ func NewCore(c *conf.CoreConfig) (Core, error) { if types := strings.Split(c.Type, " "); len(types) > 1 { var cs []Core for _, t := range types { - f, ok := cores[strings.ToLower(c.Type)] + f, ok := cores[strings.ToLower(t)] if !ok { return nil, errors.New("unknown core type: " + t) } diff --git a/core/xray/inbound.go b/core/xray/inbound.go index 96c87f0..1060574 100644 --- a/core/xray/inbound.go +++ b/core/xray/inbound.go @@ -80,7 +80,7 @@ func buildInbound(config *conf.ControllerConfig, nodeInfo *panel.NodeInfo, tag s if err != nil { return nil, fmt.Errorf("marshal reality dest error: %s", err) } - if len(in.StreamSetting.REALITYSettings.ShortIds) == 0 { + if len(config.CertConfig.RealityConfig.ShortIds) == 0 { config.CertConfig.RealityConfig.ShortIds = []string{""} } in.StreamSetting.REALITYSettings = &coreConf.REALITYConfig{