diff options
Diffstat (limited to 'src/network/doc/snippets/code/src_network_access_qrestaccessmanager.cpp')
-rw-r--r-- | src/network/doc/snippets/code/src_network_access_qrestaccessmanager.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/network/doc/snippets/code/src_network_access_qrestaccessmanager.cpp b/src/network/doc/snippets/code/src_network_access_qrestaccessmanager.cpp index e2a28d6b31..56f18beff6 100644 --- a/src/network/doc/snippets/code/src_network_access_qrestaccessmanager.cpp +++ b/src/network/doc/snippets/code/src_network_access_qrestaccessmanager.cpp @@ -31,7 +31,7 @@ manager->post(request, myJson, this, [this](QRestReply &reply) { if (!reply.isSuccess()) { // ... } - if (std::optional json = reply.json()) { + if (std::optional json = reply.readJson()) { // use *json } }); @@ -42,7 +42,7 @@ manager->post(request, myJson, this, [this](QRestReply &reply) { manager->get(request, this, [this](QRestReply &reply) { if (!reply.isSuccess()) // handle error - if (std::optional json = reply.json()) + if (std::optional json = reply.readJson()) // use *json }); //! [3] |