summaryrefslogtreecommitdiff
path: root/activitypub.c
diff options
context:
space:
mode:
authorGravatar default2024-07-30 18:34:40 +0200
committerGravatar default2024-07-30 18:34:40 +0200
commit1542a1a0a68919c0fa691783f681fc655705fd4a (patch)
treed816926224160d10a80987d07c777d32a8a838be /activitypub.c
parentNotify blocks. (diff)
downloadsnac2-1542a1a0a68919c0fa691783f681fc655705fd4a.tar.gz
snac2-1542a1a0a68919c0fa691783f681fc655705fd4a.tar.xz
snac2-1542a1a0a68919c0fa691783f681fc655705fd4a.zip
Treat 'EmojiReact' as a 'Like'.
These messages will have special treatment eventually.
Diffstat (limited to 'activitypub.c')
-rw-r--r--activitypub.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/activitypub.c b/activitypub.c
index 437cfaf..ce7e71f 100644
--- a/activitypub.c
+++ b/activitypub.c
@@ -2014,12 +2014,12 @@ int process_input_message(snac *snac, const xs_dict *msg, const xs_dict *req)
2014 } 2014 }
2015 } 2015 }
2016 else 2016 else
2017 if (strcmp(type, "Like") == 0) { /** **/ 2017 if (strcmp(type, "Like") == 0 || strcmp(type, "EmojiReact") == 0) { /** **/
2018 if (xs_type(object) == XSTYPE_DICT) 2018 if (xs_type(object) == XSTYPE_DICT)
2019 object = xs_dict_get(object, "id"); 2019 object = xs_dict_get(object, "id");
2020 2020
2021 if (timeline_admire(snac, object, actor, 1) == HTTP_STATUS_CREATED) 2021 if (timeline_admire(snac, object, actor, 1) == HTTP_STATUS_CREATED)
2022 snac_log(snac, xs_fmt("new 'Like' %s %s", actor, object)); 2022 snac_log(snac, xs_fmt("new '%s' %s %s", type, actor, object));
2023 else 2023 else
2024 snac_log(snac, xs_fmt("repeated 'Like' from %s to %s", actor, object)); 2024 snac_log(snac, xs_fmt("repeated 'Like' from %s to %s", actor, object));
2025 2025