Skip to content

Commit

Permalink
Make message received notification skip smarter
Browse files Browse the repository at this point in the history
  • Loading branch information
stefanw committed Jul 1, 2024
1 parent 71b7f1d commit 2bed7f4
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions froide/foirequest/signals.py
Original file line number Diff line number Diff line change
Expand Up @@ -120,9 +120,8 @@ def send_notification_became_asleep(sender, **kwargs):

@receiver(FoiRequest.message_received, dispatch_uid="notify_user_message_received")
def notify_user_message_received(sender, message=None, **kwargs):
if message.received_by_user:
# All non-email/upload received messages the user actively contributed
# Don't inform them about it
if kwargs.get("user") == sender.user:
# If the same user has uploaded this, don't notify
return

send_request_user_email(
Expand Down

0 comments on commit 2bed7f4

Please sign in to comment.