From 3fa1ee3c6b04d0793ccca3f903797625f7a08d03 Mon Sep 17 00:00:00 2001 From: Elvis Angelaccio Date: Sun, 30 Apr 2017 15:19:31 +0200 Subject: Port to categorized logging This greatly reduces the noise made by quaternion. To enable full logging, export the following variable: QT_LOGGING_RULES="libqmatrixclient.*.debug=true" --- events/roommessageevent.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'events/roommessageevent.cpp') diff --git a/events/roommessageevent.cpp b/events/roommessageevent.cpp index f5dcb7d0..fd6de464 100644 --- a/events/roommessageevent.cpp +++ b/events/roommessageevent.cpp @@ -97,8 +97,8 @@ ContentPair makeVideo(const QJsonObject& json) ContentPair makeUnknown(const QJsonObject& json) { - qDebug() << "RoomMessageEvent: couldn't resolve msgtype, JSON follows:"; - qDebug() << json; + qCDebug(EVENTS) << "RoomMessageEvent: couldn't resolve msgtype, JSON follows:"; + qCDebug(EVENTS) << json; return { MessageEventType::Unknown, new Base }; } @@ -110,7 +110,7 @@ RoomMessageEvent* RoomMessageEvent::fromJson(const QJsonObject& obj) { e->d->userId = obj.value("sender").toString(); } else { - qDebug() << "RoomMessageEvent: user_id not found"; + qCDebug(EVENTS) << "RoomMessageEvent: user_id not found"; } if( obj.contains("content") ) { @@ -135,8 +135,8 @@ RoomMessageEvent* RoomMessageEvent::fromJson(const QJsonObject& obj) } else { - qWarning() << "RoomMessageEvent(" << e->id() << "): no body or msgtype"; - qDebug() << obj; + qCWarning(EVENTS) << "RoomMessageEvent(" << e->id() << "): no body or msgtype"; + qCDebug(EVENTS) << obj; } } return e; -- cgit v1.2.3