2
0
mirror of https://github.com/acepanel/panel.git synced 2026-02-04 11:27:17 +08:00

fix: 修正环境检查

This commit is contained in:
2026-01-09 17:12:57 +08:00
parent 1d41b2c61c
commit f48c975de3
14 changed files with 74 additions and 53 deletions

View File

@@ -132,6 +132,11 @@ func (v *baseVhost) SetEnable(enable bool) error {
return err
}
// 清理保存的根目录文件
if enable {
_ = os.RemoveAll(filepath.Join(v.configDir, "root.saved"))
}
// 设置 Include 配置
v.vhost.RemoveDirectives("IncludeOptional")
if enable {

View File

@@ -135,6 +135,11 @@ func (v *baseVhost) SetEnable(enable bool) error {
return err
}
// 清理保存的根目录文件
if enable {
_ = os.RemoveAll(filepath.Join(v.configDir, "root.saved"))
}
// 设置导入配置
_ = v.parser.Clear("server.include")
if enable {