mirror of
https://github.com/zulip/zulip.git
synced 2025-11-06 15:03:34 +00:00
create_user_messages: Rename mark_as_read_user_ids.
This should use a name that follows the naming pattern of adjacent fields.
This commit is contained in:
@@ -2059,8 +2059,8 @@ def do_send_messages(
|
|||||||
mentioned_user_ids = send_request.rendering_result.mentions_user_ids
|
mentioned_user_ids = send_request.rendering_result.mentions_user_ids
|
||||||
|
|
||||||
# Extend the set with users who have muted the sender.
|
# Extend the set with users who have muted the sender.
|
||||||
mark_as_read_for_users = send_request.muted_sender_user_ids
|
mark_as_read_user_ids = send_request.muted_sender_user_ids
|
||||||
mark_as_read_for_users.update(mark_as_read)
|
mark_as_read_user_ids.update(mark_as_read)
|
||||||
|
|
||||||
user_messages = create_user_messages(
|
user_messages = create_user_messages(
|
||||||
message=send_request.message,
|
message=send_request.message,
|
||||||
@@ -2070,7 +2070,7 @@ def do_send_messages(
|
|||||||
stream_push_user_ids=send_request.stream_push_user_ids,
|
stream_push_user_ids=send_request.stream_push_user_ids,
|
||||||
stream_email_user_ids=send_request.stream_email_user_ids,
|
stream_email_user_ids=send_request.stream_email_user_ids,
|
||||||
mentioned_user_ids=mentioned_user_ids,
|
mentioned_user_ids=mentioned_user_ids,
|
||||||
mark_as_read_for_users=mark_as_read_for_users,
|
mark_as_read_user_ids=mark_as_read_user_ids,
|
||||||
limit_unread_user_ids=send_request.limit_unread_user_ids,
|
limit_unread_user_ids=send_request.limit_unread_user_ids,
|
||||||
)
|
)
|
||||||
|
|
||||||
@@ -2282,7 +2282,7 @@ def create_user_messages(
|
|||||||
stream_push_user_ids: AbstractSet[int],
|
stream_push_user_ids: AbstractSet[int],
|
||||||
stream_email_user_ids: AbstractSet[int],
|
stream_email_user_ids: AbstractSet[int],
|
||||||
mentioned_user_ids: AbstractSet[int],
|
mentioned_user_ids: AbstractSet[int],
|
||||||
mark_as_read_for_users: Set[int],
|
mark_as_read_user_ids: Set[int],
|
||||||
limit_unread_user_ids: Optional[Set[int]],
|
limit_unread_user_ids: Optional[Set[int]],
|
||||||
) -> List[UserMessageLite]:
|
) -> List[UserMessageLite]:
|
||||||
# These properties on the Message are set via
|
# These properties on the Message are set via
|
||||||
@@ -2321,7 +2321,7 @@ def create_user_messages(
|
|||||||
flags = base_flags
|
flags = base_flags
|
||||||
if (
|
if (
|
||||||
(user_profile_id == sender_id and message.sent_by_human())
|
(user_profile_id == sender_id and message.sent_by_human())
|
||||||
or user_profile_id in mark_as_read_for_users
|
or user_profile_id in mark_as_read_user_ids
|
||||||
or (limit_unread_user_ids is not None and user_profile_id not in limit_unread_user_ids)
|
or (limit_unread_user_ids is not None and user_profile_id not in limit_unread_user_ids)
|
||||||
):
|
):
|
||||||
flags |= UserMessage.flags.read
|
flags |= UserMessage.flags.read
|
||||||
|
|||||||
Reference in New Issue
Block a user