diff options
author | default <nobody@localhost> | 2022-09-26 09:28:39 +0200 |
---|---|---|
committer | default <nobody@localhost> | 2022-09-26 09:28:39 +0200 |
commit | f410e3a40a9943e8c657a886f3c8e343374da45e (patch) | |
tree | dc7fc219e89b4ef23f8f82043e755ac9ba96a5ae /activitypub.c | |
parent | c37a99b97cb6f3214b87d4a1c1e16a8b30d4ef52 (diff) |
New function post.
Diffstat (limited to 'activitypub.c')
-rw-r--r-- | activitypub.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/activitypub.c b/activitypub.c index 923028c..f08c44c 100644 --- a/activitypub.c +++ b/activitypub.c @@ -431,6 +431,19 @@ int is_msg_public(snac *snac, char *msg) } +void post(snac *snac, char *msg) +/* enqueues a message to all its recipients */ +{ + xs *rcpts = recipient_list(snac, msg, 1); + char *p, *v; + + p = rcpts; + while (xs_list_iter(&p, &v)) { + enqueue_output(snac, msg, v, 0); + } +} + + /** HTTP handlers */ int activitypub_get_handler(d_char *req, char *q_path, |