diff options
| -rw-r--r-- | activitypub.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/activitypub.c b/activitypub.c index b658fbc..35601fb 100644 --- a/activitypub.c +++ b/activitypub.c | |||
| @@ -1670,8 +1670,10 @@ int process_input_message(snac *snac, xs_dict *msg, xs_dict *req) | |||
| 1670 | } | 1670 | } |
| 1671 | else | 1671 | else |
| 1672 | if (strcmp(type, "Create") == 0) { /** **/ | 1672 | if (strcmp(type, "Create") == 0) { /** **/ |
| 1673 | if (is_muted(snac, actor)) | 1673 | if (is_muted(snac, actor)) { |
| 1674 | snac_log(snac, xs_fmt("ignored 'Create' + '%s' from muted actor %s", utype, actor)); | 1674 | snac_log(snac, xs_fmt("ignored 'Create' + '%s' from muted actor %s", utype, actor)); |
| 1675 | return 1; | ||
| 1676 | } | ||
| 1675 | 1677 | ||
| 1676 | if (strcmp(utype, "Note") == 0) { /** **/ | 1678 | if (strcmp(utype, "Note") == 0) { /** **/ |
| 1677 | char *id = xs_dict_get(object, "id"); | 1679 | char *id = xs_dict_get(object, "id"); |
| @@ -1751,6 +1753,9 @@ int process_input_message(snac *snac, xs_dict *msg, xs_dict *req) | |||
| 1751 | if (xs_type(object) == XSTYPE_DICT) | 1753 | if (xs_type(object) == XSTYPE_DICT) |
| 1752 | object = xs_dict_get(object, "id"); | 1754 | object = xs_dict_get(object, "id"); |
| 1753 | 1755 | ||
| 1756 | if (is_muted(snac, actor) && !xs_startswith(object, snac->actor)) | ||
| 1757 | snac_log(snac, xs_fmt("dropped 'Announce' from muted actor %s", actor)); | ||
| 1758 | else | ||
| 1754 | if (is_limited(snac, actor) && !xs_startswith(object, snac->actor)) | 1759 | if (is_limited(snac, actor) && !xs_startswith(object, snac->actor)) |
| 1755 | snac_log(snac, xs_fmt("dropped 'Announce' from limited actor %s", actor)); | 1760 | snac_log(snac, xs_fmt("dropped 'Announce' from limited actor %s", actor)); |
| 1756 | else { | 1761 | else { |