summaryrefslogtreecommitdiff
path: root/activitypub.c
diff options
context:
space:
mode:
authordefault <nobody@localhost>2023-06-02 10:52:05 +0200
committerdefault <nobody@localhost>2023-06-02 10:52:12 +0200
commitb0337f55b5c0afe32231f1efffe7aa184319b7e3 (patch)
tree2a9d1c62d44cbabdc8bc01921b5ef77626c3fcbd /activitypub.c
parent2e19c193a09c57f4e3f6d65b3909fbb42cc12a63 (diff)
Fixed bug in vote discarding in notify().
Diffstat (limited to 'activitypub.c')
-rw-r--r--activitypub.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/activitypub.c b/activitypub.c
index 4919a61..c28e52f 100644
--- a/activitypub.c
+++ b/activitypub.c
@@ -499,7 +499,9 @@ void notify(snac *snac, const char *type, const char *utype, const char *actor,
return;
/* discard votes */
- if (!xs_is_null(xs_dict_get(msg, "name")))
+ const xs_dict *note = xs_dict_get(msg, "object");
+
+ if (note && !xs_is_null(xs_dict_get(note, "name")))
return;
}