diff --git a/fmt/Bean2Link.cpp b/fmt/Bean2Link.cpp index d74338989..0209a715b 100644 --- a/fmt/Bean2Link.cpp +++ b/fmt/Bean2Link.cpp @@ -235,7 +235,7 @@ namespace NekoGui_fmt { q.addQueryItem("obfs", "salamander"); q.addQueryItem("obfs-password", obfsPassword); } - // if (!hopPort.trimmed().isEmpty()) q.addQueryItem("mport", hopPort); + if (!hopPort.trimmed().isEmpty()) q.addQueryItem("mport", hopPort); if (allowInsecure) q.addQueryItem("insecure", "1"); if (!sni.isEmpty()) q.addQueryItem("sni", sni); if (!q.isEmpty()) url.setQuery(q); diff --git a/fmt/Link2Bean.cpp b/fmt/Link2Bean.cpp index 792ad183a..b4f2fae18 100644 --- a/fmt/Link2Bean.cpp +++ b/fmt/Link2Bean.cpp @@ -287,7 +287,7 @@ namespace NekoGui_fmt { name = url.fragment(QUrl::FullyDecoded); serverAddress = url.host(); serverPort = url.port(); - // hopPort = query.queryItemValue("mport"); + hopPort = query.queryItemValue("mport"); obfsPassword = query.queryItemValue("obfs-password"); allowInsecure = QStringList{"1", "true"}.contains(query.queryItemValue("insecure"));