mirror of
https://github.com/asdlokj1qpi233/subconverter.git
synced 2026-11-02 17:52:19 +00:00
fix vless short_id issue.(#1)
This commit is contained in:
1 parent
927c828a27
commit
ebad0e96f7
1 file changed
+6
-2
@@ -2409,8 +2409,12 @@ proxyToSingBox(std::vector<Proxy> &nodes, rapidjson::Document &json, std::vector
|
||||
if (!x.PublicKey.empty()) {
|
||||
reality.AddMember("public_key", rapidjson::StringRef(x.PublicKey.c_str()), allocator);
|
||||
}
|
||||
auto shortIds = stringArrayToJsonArray(x.Alpn, ",", allocator);
|
||||
reality.AddMember("short_id", shortIds, allocator);
|
||||
// auto shortIds = stringArrayToJsonArray(x.ShortId, ",", allocator);
|
||||
if (!x.ShortId.empty()) {
|
||||
reality.AddMember("short_id", rapidjson::StringRef(x.ShortId.c_str()), allocator);
|
||||
} else {
|
||||
reality.AddMember("short_id", rapidjson::StringRef(""), allocator);
|
||||
}
|
||||
tls.AddMember("reality", reality, allocator);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user