Skip to content

Commit 7ce2fa6

Browse files
committed
fix: 修复 Egern VLESS flow
1 parent f22e7bc commit 7ce2fa6

2 files changed

Lines changed: 8 additions & 10 deletions

File tree

backend/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "sub-store",
3-
"version": "2.21.27",
3+
"version": "2.21.28",
44
"description": "Advanced Subscription Manager for QX, Loon, Surge, Stash and Shadowrocket.",
55
"main": "src/main.js",
66
"scripts": {

backend/src/core/proxy-utils/producers/egern.js

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -64,8 +64,12 @@ export default function Egern_Producer() {
6464
!['http', 'ws', 'tcp'].includes(proxy.network) &&
6565
proxy.network) ||
6666
(proxy.type === 'vless' &&
67-
!['http', 'ws', 'tcp'].includes(proxy.network) &&
68-
proxy.network) ||
67+
((!['http', 'ws', 'tcp'].includes(proxy.network) &&
68+
proxy.network) ||
69+
(typeof proxy.flow !== 'undefined' &&
70+
!['xtls-rprx-vision', ''].includes(
71+
proxy.flow,
72+
)))) ||
6973
(proxy.type === 'tuic' &&
7074
proxy.token &&
7175
proxy.token.length !== 0)
@@ -353,14 +357,8 @@ export default function Egern_Producer() {
353357
reality,
354358
},
355359
};
356-
if (typeof proxy.flow !== 'undefined') {
357-
if (!['xtls-rprx-vision'].includes(proxy.flow)) {
358-
throw new Error(
359-
`VLESS flow(${proxy.flow}) is not supported`,
360-
);
361-
}
362-
}
363360
flow = proxy.flow;
361+
if (flow === '') flow = undefined;
364362
}
365363
proxy = {
366364
type: 'vless',

0 commit comments

Comments
 (0)