mirror of
https://github.com/zulip/zulip.git
synced 2025-11-02 13:03:29 +00:00
send_email: Use a consistent order when sending custom emails to users.
This commit is contained in:
committed by
Tim Abbott
parent
54b399ce96
commit
4f4627b79b
@@ -152,7 +152,9 @@ server via `ps -ef` or reading bash history. Prefer
|
||||
if realm is not None:
|
||||
user_profiles = user_profiles.filter(realm=realm)
|
||||
email_matches = [Q(delivery_email__iexact=e) for e in emails]
|
||||
user_profiles = user_profiles.filter(reduce(lambda a, b: a | b, email_matches))
|
||||
user_profiles = user_profiles.filter(reduce(lambda a, b: a | b, email_matches)).order_by(
|
||||
"id"
|
||||
)
|
||||
|
||||
# Return the single query, for ease of composing.
|
||||
return user_profiles
|
||||
|
||||
Reference in New Issue
Block a user