aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexey Rusakov <Kitsune-Ral@users.sf.net>2021-09-12 04:36:13 +0200
committerAlexey Rusakov <Kitsune-Ral@users.sf.net>2021-09-12 04:36:13 +0200
commit2c61b463fa0608626a58aed79ebecb3bbd8c41d3 (patch)
treeb80c9eb342757d1371495276145e82653dd8d50e
parent693b5da2920f173a9e3f723b845d35a7b4aa9823 (diff)
downloadlibquotient-2c61b463fa0608626a58aed79ebecb3bbd8c41d3.tar.gz
libquotient-2c61b463fa0608626a58aed79ebecb3bbd8c41d3.zip
NAM::createRequest(): more logging
-rw-r--r--lib/networkaccessmanager.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/networkaccessmanager.cpp b/lib/networkaccessmanager.cpp
index d35b2ec8..57618329 100644
--- a/lib/networkaccessmanager.cpp
+++ b/lib/networkaccessmanager.cpp
@@ -93,6 +93,7 @@ QNetworkReply* NetworkAccessManager::createRequest(
// doesn't provide multithreading guarantees
static thread_local QSettings s;
if (!s.value("Network/allow_direct_media_requests").toBool()) {
+ qCWarning(NETWORK) << "No connection specified";
return new MxcReply();
}
// TODO: Make the best effort with a direct unauthenticated request
@@ -100,14 +101,14 @@ QNetworkReply* NetworkAccessManager::createRequest(
} else {
auto* const connection = AccountRegistry::instance().get(accountId);
if (!connection) {
- qCWarning(NETWORK) << "Connection not found";
+ qCWarning(NETWORK) << "Connection" << accountId << "not found";
return new MxcReply();
}
const auto roomId = query.queryItemValue(QStringLiteral("room_id"));
if (!roomId.isEmpty()) {
auto room = connection->room(roomId);
if (!room) {
- qCWarning(NETWORK) << "Room not found";
+ qCWarning(NETWORK) << "Room" << roomId << "not found";
return new MxcReply();
}
return new MxcReply(