diff options
author | Kitsune Ral <Kitsune-Ral@users.sf.net> | 2018-07-02 17:58:34 +0900 |
---|---|---|
committer | Kitsune Ral <Kitsune-Ral@users.sf.net> | 2018-07-04 20:13:43 +0900 |
commit | 3dd6b5e6cc50aafce74b21b5a0bf4b26a9fcf6ee (patch) | |
tree | a647fa5328e04b20a84e46d29d420555d9c56cde /lib/csapi/voip.cpp | |
parent | ed467d27b07781fdd2f7ddef043568954ce50b69 (diff) | |
download | libquotient-3dd6b5e6cc50aafce74b21b5a0bf4b26a9fcf6ee.tar.gz libquotient-3dd6b5e6cc50aafce74b21b5a0bf4b26a9fcf6ee.zip |
Use QStringLiteral() and operator"" _ls() in network jobs
Diffstat (limited to 'lib/csapi/voip.cpp')
-rw-r--r-- | lib/csapi/voip.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/lib/csapi/voip.cpp b/lib/csapi/voip.cpp index f84c140d..8ecf92c6 100644 --- a/lib/csapi/voip.cpp +++ b/lib/csapi/voip.cpp @@ -24,8 +24,10 @@ QUrl GetTurnServerJob::makeRequestUrl(QUrl baseUrl) basePath % "/voip/turnServer"); } +static const auto GetTurnServerJobName = QStringLiteral("GetTurnServerJob"); + GetTurnServerJob::GetTurnServerJob() - : BaseJob(HttpVerb::Get, "GetTurnServerJob", + : BaseJob(HttpVerb::Get, GetTurnServerJobName, basePath % "/voip/turnServer") , d(new Private) { @@ -41,10 +43,10 @@ const QJsonObject& GetTurnServerJob::data() const BaseJob::Status GetTurnServerJob::parseJson(const QJsonDocument& data) { auto json = data.object(); - if (!json.contains("data")) + if (!json.contains("data"_ls)) return { JsonParseError, "The key 'data' not found in the response" }; - d->data = fromJson<QJsonObject>(json.value("data")); + d->data = fromJson<QJsonObject>(json.value("data"_ls)); return Success; } |