mirror of
https://github.com/daeuniverse/dae.git
synced 2025-07-11 00:09:18 +07:00
chore: remove unused patches
This commit is contained in:
@ -6,7 +6,6 @@
|
|||||||
package config
|
package config
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
|
||||||
"github.com/daeuniverse/dae/common/consts"
|
"github.com/daeuniverse/dae/common/consts"
|
||||||
)
|
)
|
||||||
|
|
||||||
@ -14,8 +13,6 @@ type patch func(params *Config) error
|
|||||||
|
|
||||||
var patches = []patch{
|
var patches = []patch{
|
||||||
patchEmptyDns,
|
patchEmptyDns,
|
||||||
patchDeprecatedGlobalDnsUpstream,
|
|
||||||
patchDeprecatedLanNatDirect,
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func patchEmptyDns(params *Config) error {
|
func patchEmptyDns(params *Config) error {
|
||||||
@ -27,18 +24,3 @@ func patchEmptyDns(params *Config) error {
|
|||||||
}
|
}
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func patchDeprecatedGlobalDnsUpstream(params *Config) error {
|
|
||||||
if params.Global.DnsUpstream != "<empty>" {
|
|
||||||
return fmt.Errorf("'global.dns_upstream' was deprecated, please refer to the latest examples and docs for help")
|
|
||||||
}
|
|
||||||
params.Global.DnsUpstream = ""
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
func patchDeprecatedLanNatDirect(params *Config) error {
|
|
||||||
if params.Global.LanNatDirect != false {
|
|
||||||
return fmt.Errorf("'global.lan_nat_direct' was deprecated; please remove it")
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
Reference in New Issue
Block a user