mirror of
https://codeberg.org/rimu/pyfedi
synced 2025-01-23 19:36:56 -08:00
Also ignore it if a.gup.pe announces local content back
This commit is contained in:
parent
01e28a20b5
commit
0b66127d40
1 changed files with 3 additions and 0 deletions
|
@ -947,6 +947,9 @@ def process_inbox_request(request_json, store_ap_json):
|
|||
# Announce is new content and votes that happened on a remote server.
|
||||
if request_json['type'] == 'Announce':
|
||||
if isinstance(request_json['object'], str): # Mastodon, PeerTube, A.gup.pe
|
||||
if request_json['object'].startswith('https://' + current_app.config['SERVER_NAME']):
|
||||
log_incoming_ap(announce_id, APLOG_DUPLICATE, APLOG_IGNORED, request_json if store_ap_json else None, 'Activity about local content which is already present')
|
||||
return
|
||||
post = resolve_remote_post(request_json['object'], community.id, announce_actor=community.ap_profile_id, store_ap_json=store_ap_json)
|
||||
if post:
|
||||
log_incoming_ap(announce_id, APLOG_ANNOUNCE, APLOG_SUCCESS, request_json)
|
||||
|
|
Loading…
Reference in a new issue