diff options
Diffstat (limited to 'activitypub.c')
| -rw-r--r-- | activitypub.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/activitypub.c b/activitypub.c index 702840c..24cf49d 100644 --- a/activitypub.c +++ b/activitypub.c | |||
| @@ -1558,15 +1558,15 @@ int process_input_message(snac *snac, xs_dict *msg, xs_dict *req) | |||
| 1558 | } | 1558 | } |
| 1559 | else | 1559 | else |
| 1560 | if (strcmp(type, "Announce") == 0) { /** **/ | 1560 | if (strcmp(type, "Announce") == 0) { /** **/ |
| 1561 | if (is_limited(snac, actor)) | 1561 | if (xs_type(object) == XSTYPE_DICT) |
| 1562 | object = xs_dict_get(object, "id"); | ||
| 1563 | |||
| 1564 | if (is_limited(snac, actor) && !xs_startswith(object, snac->actor)) | ||
| 1562 | snac_log(snac, xs_fmt("dropped 'Announce' from limited actor %s", actor)); | 1565 | snac_log(snac, xs_fmt("dropped 'Announce' from limited actor %s", actor)); |
| 1563 | else { | 1566 | else { |
| 1564 | xs *a_msg = NULL; | 1567 | xs *a_msg = NULL; |
| 1565 | xs *wrk = NULL; | 1568 | xs *wrk = NULL; |
| 1566 | 1569 | ||
| 1567 | if (xs_type(object) == XSTYPE_DICT) | ||
| 1568 | object = xs_dict_get(object, "id"); | ||
| 1569 | |||
| 1570 | timeline_request(snac, &object, &wrk, 0); | 1570 | timeline_request(snac, &object, &wrk, 0); |
| 1571 | 1571 | ||
| 1572 | if (valid_status(object_get(object, &a_msg))) { | 1572 | if (valid_status(object_get(object, &a_msg))) { |