add: added default vmess "type" field

This commit is contained in:
Qv2ray-dev 2020-05-06 17:27:14 +08:00 committed by GitHub
parent 407436ffba
commit a3ce8015d6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -52,6 +52,11 @@ namespace Qv2ray::core::connection
vmessUriRoot["host"] = transfer.httpSettings.host.join(",");
vmessUriRoot["path"] = transfer.httpSettings.path;
}
if(!vmessUriRoot.contains("type") || vmessUriRoot["type"].toString().isEmpty())
{
vmessUriRoot["type"] = "none";
}
//
auto vmessPart = Base64Encode(JsonToString(vmessUriRoot, QJsonDocument::JsonFormat::Compact));