Anyone has idea how to quickly copy nlohmann::json MAP values to an other nlohmann::json?
nlohmann::json j1;
nlohmann::json j2;
j1["MAP"]["value1"] = 1;
j2["MAP"]["value2"] = 2;
j2["MAP"] += j1["MAP"];
This will throw because += will think that I am adding a value to a list.
[json.exception.type_error.308] cannot use push_back() with object
I can enumerate j1["MAP"] and add them into j2["MAP"] but I was wondering if there is a straightforward method.