Undo moving of a thread does not work flawlessly

Description

When moving threads to another folder everything works. The thread includes mails received and mails sent by from the mailbox.

When using EditUndo to undo this, the thread is restored in the sent folder. However the including mails that are received by the mailbox should be moved to the inbox instead and only be shown in the sent folder in a thread.

sent folder:
Original thread:

  • Sent Mail S1 (Sent folder)
  • Received Mail R1 (Inbox)
  • Sent Mail S2 (Sent folder)

Thread after moving to folder and undo:

  • Sent Mail S1 (Sent folder)
  • Received Mail R1 (Sent folder)
  • Sent Mail S2 (Sent folder)

Fix / Workaround

I could only fix this by moving the mail R1 via another client to the inbox. Afterwords, the thread was shown normally again.

To Reproduce…

Steps to reproduce the behavior:

  1. Move thread of sent and received mails to another folder
  2. Undo
  3. See wrong folder

Expected Behavior

All mails included in a thread should be moved back into their original folder instead of moving the complete thread into one folder

Setup

  • OS and Version: Ubuntu 24.04 LTS
  • Installation Method: apt
  • Mailspring Version: Version 1.13.3-9a7e1a78