mirror of https://github.com/zulip/zulip.git
Read read flags from UserMessage not Message
(imported from commit 4c0f6ec90992c61ba861f5f347655673e769bebc)
This commit is contained in:
parent
da81bcae0e
commit
4f2cb1bc1c
|
@ -2012,9 +2012,10 @@ def do_send_missedmessage_events(user_profile, missed_messages):
|
||||||
@statsd_increment("push_notifications")
|
@statsd_increment("push_notifications")
|
||||||
def handle_push_notification(user_profile_id, missed_message):
|
def handle_push_notification(user_profile_id, missed_message):
|
||||||
user_profile = get_user_profile_by_id(user_profile_id)
|
user_profile = get_user_profile_by_id(user_profile_id)
|
||||||
message = UserMessage.objects.get(user_profile=user_profile,
|
umessage = UserMessage.objects.get(user_profile=user_profile,
|
||||||
message__id=missed_message['message_id']).message
|
message__id=missed_message['message_id']).message
|
||||||
if message.flags.read:
|
message = umessage.message
|
||||||
|
if umessage.flags.read:
|
||||||
return
|
return
|
||||||
sender_str = message.sender.full_name
|
sender_str = message.sender.full_name
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue