mologram
#include "mologram/Rpc.hpp"
namespace mologram {
js::Value RpcError::toJson() const {
js::Object o;
o["code"] = js::Value(code);
o["text"] = js::Value(text);
return js::Value(std::move(o));
}
RpcError RpcError::fromJson(const js::Value& v) { return {js::getStr(v, "code"), js::getStr(v, "text")}; }
} // namespace mologram