commit 24cd0c1
default
·
2024-01-24 17:50:57 +0000 UTC
parent 9a5e0a2
Don't send anything to the collected inboxes if collection is disabled.
1 files changed,
+9,
-7
+9,
-7
1@@ -1991,13 +1991,15 @@ void process_user_queue_item(snac *snac, xs_dict *q_item)
2
3 /* if it's public, send to the collected inboxes */
4 if (is_msg_public(msg)) {
5- xs *shibx = inbox_list();
6- xs_str *inbox;
7-
8- p = shibx;
9- while (xs_list_iter(&p, &inbox)) {
10- if (xs_set_add(&inboxes, inbox) == 1)
11- enqueue_output(snac, msg, inbox, 0, 0);
12+ if (xs_type(xs_dict_get(srv_config, "disable_inbox_collection")) != XSTYPE_TRUE) {
13+ xs *shibx = inbox_list();
14+ xs_str *inbox;
15+
16+ p = shibx;
17+ while (xs_list_iter(&p, &inbox)) {
18+ if (xs_set_add(&inboxes, inbox) == 1)
19+ enqueue_output(snac, msg, inbox, 0, 0);
20+ }
21 }
22 }
23