mirror of
https://github.com/martinrotter/rssguard.git
synced 2024-12-27 08:33:27 +01:00
log network code on token response
This commit is contained in:
parent
9ec9c891c5
commit
d07c51d831
@ -470,7 +470,7 @@ void Application::showGuiMessage(Notification::Event event, const QString& title
|
||||
MessageBox::show(parent == nullptr ? mainFormWidget() : parent, QMessageBox::Icon(message_type), title, message);
|
||||
}
|
||||
else {
|
||||
qDebugNN << LOGSEC_CORE << "Silencing GUI message: '" << message << "'.";
|
||||
qDebugNN << LOGSEC_CORE << "Silencing GUI message:" << QUOTE_W_SPACE_DOT(message);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -203,7 +203,7 @@ void OAuth2Service::tokenRequestFinished(QNetworkReply* network_reply) {
|
||||
QJsonDocument json_document = QJsonDocument::fromJson(repl);
|
||||
QJsonObject root_obj = json_document.object();
|
||||
|
||||
qDebugNN << LOGSEC_OAUTH << "Token response:" << QUOTE_W_SPACE_DOT(json_document.toJson());
|
||||
qDebugNN << LOGSEC_OAUTH << "Token response:" << QUOTE_W_SPACE_DOT(QString::fromUtf8(json_document.toJson()));
|
||||
|
||||
if (network_reply->error() != QNetworkReply::NetworkError::NoError) {
|
||||
qWarningNN << LOGSEC_OAUTH
|
||||
@ -216,6 +216,11 @@ void OAuth2Service::tokenRequestFinished(QNetworkReply* network_reply) {
|
||||
QString error = root_obj.value("error").toString();
|
||||
QString error_description = root_obj.value("error_description").toString();
|
||||
|
||||
qWarningNN << LOGSEC_OAUTH
|
||||
<< "JSON error when obtaining token response:"
|
||||
<< QUOTE_W_SPACE(error)
|
||||
<< QUOTE_W_SPACE_DOT(error_description);
|
||||
|
||||
logout();
|
||||
|
||||
emit tokensRetrieveError(error, error_description);
|
||||
|
Loading…
Reference in New Issue
Block a user