Move ssb.appendMessageWithIdentity's DB work off the main thread.

This commit is contained in:
2024-06-16 07:51:06 -04:00
parent 2bc71a18a6
commit 991022adfc
4 changed files with 70 additions and 35 deletions

View File

@ -278,9 +278,11 @@ void tf_ssb_run(tf_ssb_t* ssb);
** @param author The author's public key.
** @param private_key The author's private key.
** @param message The message to sign.
** @param previous_id The ID of the previous message in the feed. Optional.
** @param previous_sequence The sequence number of the previous message in the feed. Optional.
** @return The signed message.
*/
JSValue tf_ssb_sign_message(tf_ssb_t* ssb, const char* author, const uint8_t* private_key, JSValue message);
JSValue tf_ssb_sign_message(tf_ssb_t* ssb, const char* author, const uint8_t* private_key, JSValue message, const char* previous_id, int64_t previous_sequence);
/**
** Get the server's identity.