Browse Source

Merge pull request 'JSON-198' (#8) from JSON-198 into master

Reviewed-on: https://gitea.pep.foundation/pEp.foundation/pEpJSONServerAdapter/pulls/8
JSON-200
roker 2 months ago
parent
commit
653dfd406c
1 changed files with 2 additions and 0 deletions
  1. +2
    -0
      server/pEp-types.cc

+ 2
- 0
server/pEp-types.cc View File

@ -252,6 +252,7 @@ message* from_json<message*>(const js::Value& v)
msg->comments = from_json_object<char*, js::str_type>(o, "comments");
msg->opt_fields = from_json_object<stringpair_list_t*, js::array_type>(o, "opt_fields");
msg->enc_format = from_json_object<PEP_enc_format, js::int_type>(o, "enc_format");
msg->rating = from_json_object<PEP_rating, js::obj_type>(o, "rating");
return msg.release();
}
@ -345,6 +346,7 @@ js::Value to_json<message const*>(message const* const& msg)
to_json_object(o, "comments", msg->comments);
to_json_object(o, "opt_fields", msg->opt_fields);
to_json_object(o, "enc_format", msg->enc_format);
to_json_object(o, "rating", msg->rating);
return js::Value( std::move(o) );
}


Loading…
Cancel
Save