diff options
| author | 2024-10-30 16:57:27 +0100 | |
|---|---|---|
| committer | 2024-10-30 16:57:27 +0100 | |
| commit | a1231c1cd21f93fef6573d8906d852bf49165364 (patch) | |
| tree | 4316802ae8c1fb91252baeb42449725575bf57d0 | |
| parent | Set some HTML url fields to be type 'url'. (diff) | |
| download | snac2-a1231c1cd21f93fef6573d8906d852bf49165364.tar.gz snac2-a1231c1cd21f93fef6573d8906d852bf49165364.tar.xz snac2-a1231c1cd21f93fef6573d8906d852bf49165364.zip | |
Don't notify 'Block' activities if the 'disable_block_notifications' server setting is true.
| -rw-r--r-- | activitypub.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/activitypub.c b/activitypub.c index 5b9e2fe..96c3038 100644 --- a/activitypub.c +++ b/activitypub.c | |||
| @@ -2190,12 +2190,13 @@ int process_input_message(snac *snac, const xs_dict *msg, const xs_dict *req) | |||
| 2190 | } | 2190 | } |
| 2191 | else | 2191 | else |
| 2192 | if (strcmp(type, "Block") == 0) { /** **/ | 2192 | if (strcmp(type, "Block") == 0) { /** **/ |
| 2193 | snac_log(snac, xs_fmt("'Block' received from %s", actor)); | 2193 | snac_debug(snac, 1, xs_fmt("'Block' received from %s", actor)); |
| 2194 | 2194 | ||
| 2195 | /* should we MUTE the actor back? */ | 2195 | /* should we MUTE the actor back? */ |
| 2196 | /* mute(snac, actor); */ | 2196 | /* mute(snac, actor); */ |
| 2197 | 2197 | ||
| 2198 | do_notify = 1; | 2198 | if (!xs_is_true(xs_dict_get(srv_config, "disable_block_notifications"))) |
| 2199 | do_notify = 1; | ||
| 2199 | } | 2200 | } |
| 2200 | else | 2201 | else |
| 2201 | if (strcmp(type, "Move") == 0) { /** **/ | 2202 | if (strcmp(type, "Move") == 0) { /** **/ |