mirror of https://github.com/zulip/zulip.git
export_messages_single_user: Fix missing order_by.
This fixes a nasty bug where exporting messages sent by a single user might only contain some of the messages in the event that the unspecified sort order by the database didn't happen to be sorted by message ID.
This commit is contained in:
parent
f952114010
commit
f0a65fe52a
|
@ -1148,7 +1148,7 @@ def get_single_user_config():
|
|||
|
||||
def export_messages_single_user(user_profile, chunk_size=1000, output_dir=None):
|
||||
# type: (UserProfile, int, Path) -> None
|
||||
user_message_query = UserMessage.objects.filter(user_profile=user_profile)
|
||||
user_message_query = UserMessage.objects.filter(user_profile=user_profile).order_by("id")
|
||||
min_id = -1
|
||||
dump_file_id = 1
|
||||
while True:
|
||||
|
|
Loading…
Reference in New Issue