From bae703154a26702524841df19ae4ab2c9c49c61d Mon Sep 17 00:00:00 2001 From: Karl Oczadly Date: Mon, 7 Sep 2020 18:59:55 +0100 Subject: [PATCH] Fix error in json_handler from previous commit. --- nano/node/json_handler.cpp | 2 +- nano/rpc_test/rpc.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/nano/node/json_handler.cpp b/nano/node/json_handler.cpp index 377f954f36..2cf54d8783 100644 --- a/nano/node/json_handler.cpp +++ b/nano/node/json_handler.cpp @@ -4867,7 +4867,7 @@ void nano::json_handler::work_cancel () if (!ec) { node.observers.work_cancel.notify (hash); - rpc_l->response_l.put ("success", ""); + response_l.put ("success", ""); } response_errors (); } diff --git a/nano/rpc_test/rpc.cpp b/nano/rpc_test/rpc.cpp index 0fbebc2ef2..78abdb46d4 100644 --- a/nano/rpc_test/rpc.cpp +++ b/nano/rpc_test/rpc.cpp @@ -2999,7 +2999,7 @@ TEST (rpc, work_cancel) ASSERT_TIMELY (10s, response1.status != 0); ASSERT_EQ (200, response1.status); ASSERT_NO_ERROR (ec); - std::string success (response.json.get ("success")); + std::string success (response1.json.get ("success")); ASSERT_TRUE (success.empty ()); } }