diff --git a/src/dht_proxy_server.cpp b/src/dht_proxy_server.cpp index 8abc7f4f2..0c4871208 100644 --- a/src/dht_proxy_server.cpp +++ b/src/dht_proxy_server.cpp @@ -1061,7 +1061,7 @@ DhtProxyServer::sendPushNotification(const std::string& token, Json::Value&& jso std::shared_ptr request; http::Url tokenUrl(token); if (type == PushType::UnifiedPush) - request = std::make_shared(io_context(), tokenUrl.protocol + "://" + tokenUrl.host, logger_); + request = std::make_shared(io_context(), tokenUrl.protocol + "://" + tokenUrl.host + (tokenUrl.service.empty() ? "" : (":" + tokenUrl.service)), logger_); else request = std::make_shared(io_context(), pushHostPort_.first, pushHostPort_.second, pushHostPort_.first.find("https://") == 0, logger_);; reqid = request->id();