mirror of
https://github.com/zulip/zulip.git
synced 2025-11-15 19:31:58 +00:00
notifications: Fix 'get_gcm_alert' and 'get_apns_alert_subtitle'.
The 'get_gcm_alert' and 'get_apns_alert_subtitle' functions don't include the case when the trigger is 'NotificationTriggers.FOLLOWED_TOPIC_WILDCARD_MENTION'. This commit updates the functions to include 'NotificationTriggers.FOLLOWED_TOPIC_WILDCARD_MENTION'.
This commit is contained in:
committed by
Tim Abbott
parent
5f6dd83696
commit
0bf6eb6786
@@ -672,6 +672,11 @@ def get_gcm_alert(
|
||||
return f"{sender_str} mentioned you in #{display_recipient}"
|
||||
else:
|
||||
return f"{sender_str} mentioned @{mentioned_user_group_name} in #{display_recipient}"
|
||||
elif (
|
||||
message.is_stream_message()
|
||||
and trigger == NotificationTriggers.FOLLOWED_TOPIC_WILDCARD_MENTION
|
||||
):
|
||||
return "TODO"
|
||||
elif message.is_stream_message() and trigger == NotificationTriggers.WILDCARD_MENTION:
|
||||
return f"{sender_str} mentioned everyone in #{display_recipient}"
|
||||
else:
|
||||
@@ -837,6 +842,8 @@ def get_apns_alert_subtitle(
|
||||
)
|
||||
else:
|
||||
return _("{full_name} mentioned you:").format(full_name=message.sender.full_name)
|
||||
elif trigger == NotificationTriggers.FOLLOWED_TOPIC_WILDCARD_MENTION:
|
||||
return _("TODO")
|
||||
elif trigger == NotificationTriggers.WILDCARD_MENTION:
|
||||
return _("{full_name} mentioned everyone:").format(full_name=message.sender.full_name)
|
||||
elif message.recipient.type == Recipient.PERSONAL:
|
||||
|
||||
Reference in New Issue
Block a user