summaryrefslogtreecommitdiff
path: root/activitypub.c
diff options
context:
space:
mode:
authorGravatar default2024-01-24 18:50:57 +0100
committerGravatar default2024-01-24 18:50:57 +0100
commit24cd0c11b9457f3434bde83ea3c7ba51642ff5c7 (patch)
tree44e7c689bb511f54672b06ba8e38b1c1aeac8550 /activitypub.c
parentUpdated RELEASE_NOTES. (diff)
downloadsnac2-24cd0c11b9457f3434bde83ea3c7ba51642ff5c7.tar.gz
snac2-24cd0c11b9457f3434bde83ea3c7ba51642ff5c7.tar.xz
snac2-24cd0c11b9457f3434bde83ea3c7ba51642ff5c7.zip
Don't send anything to the collected inboxes if collection is disabled.
Diffstat (limited to 'activitypub.c')
-rw-r--r--activitypub.c16
1 files changed, 9 insertions, 7 deletions
diff --git a/activitypub.c b/activitypub.c
index 03c2ddf..91195cd 100644
--- a/activitypub.c
+++ b/activitypub.c
@@ -1991,13 +1991,15 @@ void process_user_queue_item(snac *snac, xs_dict *q_item)
1991 1991
1992 /* if it's public, send to the collected inboxes */ 1992 /* if it's public, send to the collected inboxes */
1993 if (is_msg_public(msg)) { 1993 if (is_msg_public(msg)) {
1994 xs *shibx = inbox_list(); 1994 if (xs_type(xs_dict_get(srv_config, "disable_inbox_collection")) != XSTYPE_TRUE) {
1995 xs_str *inbox; 1995 xs *shibx = inbox_list();
1996 1996 xs_str *inbox;
1997 p = shibx; 1997
1998 while (xs_list_iter(&p, &inbox)) { 1998 p = shibx;
1999 if (xs_set_add(&inboxes, inbox) == 1) 1999 while (xs_list_iter(&p, &inbox)) {
2000 enqueue_output(snac, msg, inbox, 0, 0); 2000 if (xs_set_add(&inboxes, inbox) == 1)
2001 enqueue_output(snac, msg, inbox, 0, 0);
2002 }
2001 } 2003 }
2002 } 2004 }
2003 2005