Skip to content

Commit

Permalink
ATProto.send: don't require stop-following actor to be opted in
Browse files Browse the repository at this point in the history
for #1582
  • Loading branch information
snarfed committed Dec 2, 2024
1 parent df505c1 commit 9340332
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions atproto.py
Original file line number Diff line number Diff line change
Expand Up @@ -589,11 +589,7 @@ def send(to_cls, obj, url, from_user=None, orig_obj_id=None):
assert from_user
to_id = as1.get_object(obj.as1).get('id')
assert to_id
to_key = Protocol.key_for(to_id)
if not to_key:
logger.info(f'Skipping, {to_id} is opted out')
return False

to_key = Protocol.key_for(to_id, allow_opt_out=True)
follower = Follower.query(Follower.from_ == from_user.key,
Follower.to == to_key).get()
if not follower or not follower.follow:
Expand Down

0 comments on commit 9340332

Please sign in to comment.