From d45a9b84bb257e67cbc40b52c7b2f80f1f05d2be Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=88=98=E5=98=89=E4=BC=9F?= <8473136@qq.com> Date: Sun, 8 Sep 2024 21:24:55 +0800 Subject: [PATCH] =?UTF-8?q?:bug:=20=E4=BF=AE=E5=A4=8D=E5=90=AF=E5=8A=A8?= =?UTF-8?q?=E6=8A=A5=E9=94=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- electron/api/frpc.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/electron/api/frpc.ts b/electron/api/frpc.ts index be3452c..b1f092a 100644 --- a/electron/api/frpc.ts +++ b/electron/api/frpc.ts @@ -35,8 +35,8 @@ const getFrpcVersionWorkerPath = ( const isRangePort = (m: Proxy) => { return ( - (m.localPort.indexOf("-") !== -1 || m.localPort.indexOf(",") !== -1) && - (m.type === "tcp" || m.type === "udp") + (m.type === "tcp" || m.type === "udp") && + (m.localPort.indexOf("-") !== -1 || m.localPort.indexOf(",") !== -1) ); }; @@ -204,7 +204,7 @@ export const genIniConfig = (config: FrpConfig, proxys: Proxy[]) => { const proxyIni = proxys.map(m => { const rangePort = isRangePort(m); let ini = ` -[${rangePort ? 'range:' : ''}${m.name}] +[${rangePort ? "range:" : ""}${m.name}] type = "${m.type}" `; switch (m.type) {