[api] Avoid JsonDocument copy-and-swap operator= in ActionResponse ctor (#16106)

This commit is contained in:
Jonathan Swoboda authored and GitHub committed 2026-04-29 08:30:35 -04:00
1 parent 8ceada8d04
commit ae5b211c89
1 file changed
+2 -1
@@ -78,7 +78,8 @@ class ActionResponse {
: success_(success), error_message_(error_message) {
if (data == nullptr || data_len == 0)
return;
this->json_document_ = json::parse_json(data, data_len);
JsonDocument tmp = json::parse_json(data, data_len);
swap(this->json_document_, tmp);
}
#endif