Rework !344 sometimes misplaces a sent message
After !344 (merged), I can trigger sent messages to appear in the wrong session.
- Get on a slow-ish network.
- Send a message to session 1 with a large-ish attachment.
- Quickly switch to another session.
When it's set to "sent", it will appear in the wrong session.
The solution is twofold:
- Make sure to filter in the
Session
object onsession_id
- Dequeue message should set the session_id relation