Commit e7d7bc57 authored by V V's avatar V V

fixed reply_id in json and lua

parent 2bfcbf0a
......@@ -431,7 +431,10 @@ json_t *json_pack_message (struct tgl_message *M) {
}
if (M->reply_id) {
assert (json_object_set (res, "reply_id", json_integer (M->reply_id)) >= 0);
tgl_message_id_t msg_id = M->permanent_id;
msg_id.id = M->reply_id;
assert (json_object_set (res, "reply_id", json_string (print_permanent_msg_id (msg_id))) >= 0);
}
if (M->flags & TGLMF_MENTION) {
......
......@@ -482,7 +482,10 @@ void push_message (struct tgl_message *M) {
}
if (M->reply_id) {
lua_add_num_field ("reply_id", M->reply_id);
tgl_message_id_t msg_id = M->permanent_id;
msg_id.id = M->reply_id;
lua_add_string_field ("reply_id", print_permanent_msg_id (msg_id));
}
if (M->flags & TGLMF_MENTION) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment