初始化 ws-opts 以避免未定义时报错

This commit is contained in:
啊伊的伊阿 authored and GitHub committed 2025-08-11 20:44:38 +08:00
1 parent feb5bc5765
commit f5595ce87e
1 file changed
+3
@@ -203,6 +203,9 @@ export default function ClashMeta_Producer() {
const reg = /^(.*?)(?:\?ed=(\d+))?$/;
// eslint-disable-next-line no-unused-vars
const [_, path = '', ed = ''] = reg.exec(wsPath);
if (!proxy['ws-opts']) {
proxy['ws-opts'] = {};
}
proxy['ws-opts'].path = path;
if (ed !== '') {
proxy['ws-opts']['early-data-header-name'] =