fix: ensure external control source settings take effect immediately #6103

This commit is contained in:
Tunglies
2026-01-16 18:27:21 +08:00
parent d4d8ef3849
commit a5f494bda2
2 changed files with 3 additions and 0 deletions

View File

@@ -33,6 +33,7 @@
- 修复 URL Schemes 无法正常导入
- 修复 Linux 下无法安装 TUN 服务
- 修复可能的端口被占用误报
- 修复设置允许外部控制来源不能立即生效
<details>
<summary><strong> ✨ 新增功能 </strong></summary>

View File

@@ -6,6 +6,7 @@ import { useTranslation } from "react-i18next";
import { BaseDialog, Switch } from "@/components/base";
import { useClash } from "@/hooks/use-clash";
import { restartCore } from "@/services/cmds";
import { showNotice } from "@/services/notice-service";
// 定义开发环境的URL列表
@@ -134,6 +135,7 @@ export const HeaderConfiguration = forwardRef<ClashHeaderConfigingRef>(
),
},
});
await restartCore();
await mutateClash();
},
{