Skip to content

Commit

Permalink
fix: override Config from ServerConfig
Browse files Browse the repository at this point in the history
  • Loading branch information
nange committed Mar 21, 2024
1 parent 3063741 commit 4e50634
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions config.go
Original file line number Diff line number Diff line change
Expand Up @@ -333,22 +333,22 @@ func (c *Config) OverrideFrom(sc *ServerConfig) {
if sc.Timeout != 0 {
c.Timeout = sc.Timeout
}
if c.DisableTLS {
if sc.DisableTLS {
c.DisableTLS = sc.DisableTLS
}
if c.CAPath != "" {
if sc.CAPath != "" {
c.CAPath = sc.CAPath
}
if c.OutboundProto != "" {
if sc.OutboundProto != "" {
c.OutboundProto = sc.OutboundProto
}
if c.CMDInterval != "" {
if sc.CMDInterval != "" {
c.CMDInterval = sc.CMDInterval
}
if c.CMDBeforeStartup != "" {
if sc.CMDBeforeStartup != "" {
c.CMDBeforeStartup = sc.CMDBeforeStartup
}
if c.CMDIntervalTime != 0 {
if sc.CMDIntervalTime != 0 {
c.CMDIntervalTime = sc.CMDIntervalTime
}
}
Expand Down

0 comments on commit 4e50634

Please sign in to comment.