summaryrefslogtreecommitdiff
path: root/activitypub.c
diff options
context:
space:
mode:
authordefault <nobody@localhost>2024-03-22 21:26:10 +0100
committerdefault <nobody@localhost>2024-03-22 21:26:10 +0100
commit21400ca13a15d136dc083506264efd54adff16bd (patch)
treebc9f72689b540f8260b8fc36d62d3332cc969fc0 /activitypub.c
parent38110ae072a56098351652fee589b5db8b9baa0c (diff)
Don't be overzealous in avoid notifications for Likes and Announces.
Diffstat (limited to 'activitypub.c')
-rw-r--r--activitypub.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/activitypub.c b/activitypub.c
index e007c96..376082d 100644
--- a/activitypub.c
+++ b/activitypub.c
@@ -1996,12 +1996,12 @@ int process_input_message(snac *snac, xs_dict *msg, xs_dict *req)
if (xs_type(object) == XSTYPE_DICT)
object = xs_dict_get(object, "id");
- if (timeline_admire(snac, object, actor, 1) == 201) {
+ if (timeline_admire(snac, object, actor, 1) == 201)
snac_log(snac, xs_fmt("new 'Like' %s %s", actor, object));
- do_notify = 1;
- }
else
snac_log(snac, xs_fmt("repeated 'Like' from %s to %s", actor, object));
+
+ do_notify = 1;
}
else
if (strcmp(type, "Announce") == 0) { /** **/
@@ -2027,13 +2027,13 @@ int process_input_message(snac *snac, xs_dict *msg, xs_dict *req)
xs *who_o = NULL;
if (valid_status(actor_request(snac, who, &who_o))) {
- if (timeline_admire(snac, object, actor, 0) == 201) {
+ if (timeline_admire(snac, object, actor, 0) == 201)
snac_log(snac, xs_fmt("new 'Announce' %s %s", actor, object));
- do_notify = 1;
- }
else
snac_log(snac, xs_fmt("repeated 'Announce' from %s to %s",
actor, object));
+
+ do_notify = 1;
}
else
snac_debug(snac, 1, xs_fmt("dropped 'Announce' on actor request error %s", who));