From 09f1cb780345b0e975fd4d74b32c38e5e9596f63 Mon Sep 17 00:00:00 2001 From: Loïc Collignon Date: Fri, 23 Nov 2018 09:38:30 +0100 Subject: Fix json format changed since v3 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Using APIv3 the json format for a response of an API call has changed a bit, removing one extra useless level. BUG: SPECT-1973 Change-Id: If5cfcda5740cf48637257a510f030dc84e853057 Signed-off-by: Loïc Collignon --- app/mixer.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'app') diff --git a/app/mixer.cpp b/app/mixer.cpp index f231b6d..ccb16d6 100644 --- a/app/mixer.cpp +++ b/app/mixer.cpp @@ -83,7 +83,7 @@ void Mixer::getVolume(const QString& name) { // TODO: Success, update the slider qDebug() << "Volume changed: " << v; - int newVolume = v.toObject()["response"].toObject()["response"].toObject()["volnew"].toInt(); + int newVolume = v.toObject()["response"].toObject()["volnew"].toInt(); auto currentVolume = volumes_.find(name); if (currentVolume != volumes_.end() && *currentVolume == newVolume) return; -- cgit 1.2.3-korg