Changeset View
Changeset View
Standalone View
Standalone View
src/console/jobs/handshakejob.cpp
Show First 20 Lines • Show All 41 Lines • ▼ Show 20 Line(s) | 41 | connect(reply, &QNetworkReply::finished, this, [this, reply]() { | |||
---|---|---|---|---|---|
42 | if (reply->error() == QNetworkReply::NoError) { | 42 | if (reply->error() == QNetworkReply::NoError) { | ||
43 | emit info(tr("Connected to %1.").arg(m_restClient->serverInfo().url().toString())); | 43 | emit info(tr("Connected to %1.").arg(m_restClient->serverInfo().url().toString())); | ||
44 | processResponse(reply); | 44 | processResponse(reply); | ||
45 | } else { | 45 | } else { | ||
46 | emitError(reply->errorString()); | 46 | emitError(reply->errorString()); | ||
47 | } | 47 | } | ||
48 | reply->deleteLater(); | 48 | reply->deleteLater(); | ||
49 | }); | 49 | }); | ||
50 | connect(reply, &QNetworkReply::redirected, this, [this, reply](const auto &url) { | 50 | connect(reply, &QNetworkReply::redirected, this, [this](const auto &url) { | ||
51 | auto s = m_restClient->serverInfo(); | 51 | auto s = m_restClient->serverInfo(); | ||
52 | auto u = url; | 52 | auto u = url; | ||
53 | auto p = u.path(); | 53 | auto p = u.path(); | ||
54 | p.remove(QLatin1String("analytics/check_schema")); | 54 | p.remove(QLatin1String("analytics/check_schema")); | ||
55 | u.setPath(p); | 55 | u.setPath(p); | ||
56 | s.setUrl(u); | 56 | s.setUrl(u); | ||
57 | m_restClient->setServerInfo(s); | 57 | m_restClient->setServerInfo(s); | ||
58 | }); | 58 | }); | ||
Show All 25 Lines |