aboutsummaryrefslogtreecommitdiff
path: root/lib/csapi/device_management.cpp
diff options
context:
space:
mode:
authorKitsune Ral <Kitsune-Ral@users.sf.net>2018-09-29 22:22:49 +0900
committerKitsune Ral <Kitsune-Ral@users.sf.net>2018-09-29 22:22:49 +0900
commitb55334ac0fe89f780776bc4eab90ffe1ca3c57bb (patch)
tree1a45c0ccfec8f5f7ba37eb4385cdc7f61afa0c97 /lib/csapi/device_management.cpp
parentf5c2e47fa1ab84fdaffe03c30ba973d7dea5ac05 (diff)
parent1e6510790dab6b9141ae52993987b406399668cd (diff)
downloadlibquotient-b55334ac0fe89f780776bc4eab90ffe1ca3c57bb.tar.gz
libquotient-b55334ac0fe89f780776bc4eab90ffe1ca3c57bb.zip
Merge branch 'cs-api-0.4.0'
Diffstat (limited to 'lib/csapi/device_management.cpp')
-rw-r--r--lib/csapi/device_management.cpp6
1 files changed, 1 insertions, 5 deletions
diff --git a/lib/csapi/device_management.cpp b/lib/csapi/device_management.cpp
index 4418f6c9..861e1994 100644
--- a/lib/csapi/device_management.cpp
+++ b/lib/csapi/device_management.cpp
@@ -77,11 +77,7 @@ const Device& GetDeviceJob::data() const
BaseJob::Status GetDeviceJob::parseJson(const QJsonDocument& data)
{
- auto json = data.object();
- if (!json.contains("data"_ls))
- return { JsonParseError,
- "The key 'data' not found in the response" };
- d->data = fromJson<Device>(json.value("data"_ls));
+ d->data = fromJson<Device>(data);
return Success;
}