Skip to content

Commit

Permalink
fix flow
Browse files Browse the repository at this point in the history
  • Loading branch information
HystericalDragon authored and HystericalDragon committed Jul 22, 2023
1 parent ceae0e3 commit 3e0762e
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
7 changes: 7 additions & 0 deletions fmt/Bean2CoreObj_box.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,13 @@ namespace NekoGui_fmt {

QJsonObject settings;
if (proxy_type == proxy_VLESS) {
if (flow.right(7) == "-udp443") {
// 检查末尾是否包含"-udp443",如果是,则删去
flow.chop(7);
} else if (flow == "none") {
// 不使用 flow
flow = "";
}
outbound["uuid"] = password.trimmed();
outbound["flow"] = flow;
} else {
Expand Down
3 changes: 3 additions & 0 deletions fmt/Bean2CoreObj_ray.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,9 @@ namespace NekoGui_fmt {

QJsonObject settings;
if (proxy_type == proxy_VLESS) {
if (flow == "none") {
flow = "";
}
settings = QJsonObject{
{"vnext", QJsonArray{
QJsonObject{
Expand Down

0 comments on commit 3e0762e

Please sign in to comment.