update fmt

This commit is contained in:
arm64v8a
2023-06-14 15:41:44 +09:00
parent b5b1eeb707
commit f29c82a938
2 changed files with 10 additions and 5 deletions

View File

@@ -69,11 +69,9 @@ namespace NekoGui_fmt {
outbound->insert("tls", tls); outbound->insert("tls", tls);
} }
if (!packet_encoding.isEmpty()) { auto pkt = packet_encoding;
auto pkt = packet_encoding; if (pkt == "packet") pkt = "packetaddr";
if (pkt == "packet") pkt = "packetaddr"; outbound->insert("packet_encoding", pkt);
outbound->insert("packet_encoding", pkt);
}
} }
CoreObjOutboundBuildResult SocksHttpBean::BuildCoreObjSingBox() { CoreObjOutboundBuildResult SocksHttpBean::BuildCoreObjSingBox() {

View File

@@ -270,6 +270,13 @@ namespace NekoGui_sub {
if (type == "vless") { if (type == "vless") {
bean->flow = Node2QString(proxy["flow"]); bean->flow = Node2QString(proxy["flow"]);
bean->password = Node2QString(proxy["uuid"]); bean->password = Node2QString(proxy["uuid"]);
// meta vless xudp
auto xudp = proxy["xudp"];
if (xudp.IsDefined() && !xudp.IsNull() && Node2Bool(xudp) == false) {
bean->stream->packet_encoding = "";
} else {
bean->stream->packet_encoding = "xudp";
}
} else { } else {
bean->password = Node2QString(proxy["password"]); bean->password = Node2QString(proxy["password"]);
} }