diff --git a/lib/base/json.cpp b/lib/base/json.cpp index 56893308a..b721f005b 100644 --- a/lib/base/json.cpp +++ b/lib/base/json.cpp @@ -68,7 +68,7 @@ public: String GetResult(); private: - std::vector m_Result; + std::string m_Result; String m_CurrentKey; std::stack> m_CurrentSubtree; @@ -450,14 +450,14 @@ template inline String JsonEncoder::GetResult() { - return String(m_Result.begin(), m_Result.end()); + return std::move(m_Result); } template inline void JsonEncoder::AppendChar(char c) { - m_Result.emplace_back(c); + m_Result.push_back(c); } template