Open andreygursky opened 7 years ago
Well, I can think of a simple way to do it, but it would really be just a catch-up, e.g. setting time of the last received message as a per-account setting, and then querying the server for messages that arrived since, and then write them into the message window directly. Would such a thing be enough?
Oh, sorry, that's way over my head to decide (for now). More detailed description of what and how can go wrong now would be helpful.
Well, I don't think there is much that can go wrong with what I proposed. I just think that if I claim to implement the MAM XEP, a user would expect more functionality, e.g. loading all past messages (since activation of MAM for that account) instead of just the ones that were sent when the device was offline. This of course does not make much sense with encryption, since a new device won't be able to read the messages anyway.
So there are two possible solutions:
Just wanted to point out that telegram-purple implements similar functionality where archive messages are fetched from the server and displayed when the account is taken online. It doesn't preserve order in the chat view, but timestamps are displayed correctly. So, while not perfect, this is a sufficient implementation for my needs.
Any plans to move "MAM for "catchup" and offline messages" from Caveats to TODO?