diff options
| author | MarcoFalke <[email protected]> | 2016-09-30 19:58:11 +0200 |
|---|---|---|
| committer | MarcoFalke <[email protected]> | 2016-09-30 19:58:11 +0200 |
| commit | e757115164c6f73c93a2d65a289b8a54e46c669d (patch) | |
| tree | a6931a579a09cf0eb21464e3bfa0d8ae0641031b /src/univalue/lib/univalue.cpp | |
| parent | Merge #8826: Do not include env_win.cc on non-Windows systems (diff) | |
| parent | Squashed 'src/univalue/' changes from daf1285..16a1f7f (diff) | |
| download | discoin-e757115164c6f73c93a2d65a289b8a54e46c669d.tar.xz discoin-e757115164c6f73c93a2d65a289b8a54e46c669d.zip | |
Merge commit '2ca7faab4205822b06dc2ab2bbda0a9a70fce7e0' into HEAD
Diffstat (limited to 'src/univalue/lib/univalue.cpp')
| -rw-r--r-- | src/univalue/lib/univalue.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/univalue/lib/univalue.cpp b/src/univalue/lib/univalue.cpp index 1f8cee6d2..5a2860c13 100644 --- a/src/univalue/lib/univalue.cpp +++ b/src/univalue/lib/univalue.cpp @@ -283,14 +283,14 @@ const UniValue& find_value(const UniValue& obj, const std::string& name) return NullUniValue; } -std::vector<std::string> UniValue::getKeys() const +const std::vector<std::string>& UniValue::getKeys() const { if (typ != VOBJ) throw std::runtime_error("JSON value is not an object as expected"); return keys; } -std::vector<UniValue> UniValue::getValues() const +const std::vector<UniValue>& UniValue::getValues() const { if (typ != VOBJ && typ != VARR) throw std::runtime_error("JSON value is not an object or array as expected"); @@ -304,7 +304,7 @@ bool UniValue::get_bool() const return getBool(); } -std::string UniValue::get_str() const +const std::string& UniValue::get_str() const { if (typ != VSTR) throw std::runtime_error("JSON value is not a string as expected"); |