Process stanzas from mam one-by-one
This commit is contained in:
parent
51b818f916
commit
cd5dacbe29
@ -5,6 +5,8 @@
|
||||
- Bugfix: Don't treat every duplicate message ID as a message correction; since some
|
||||
clients don't use globally unique ID's this causes false positives.
|
||||
- #1712: `TypeError: plugin._features is not a function`
|
||||
- Bugfix: process stanzas from mam one-by-one in order to correctly process message
|
||||
receipts
|
||||
|
||||
## 5.0.3 (2019-09-13)
|
||||
|
||||
|
@ -126,7 +126,14 @@ converse.plugins.add('converse-mam', {
|
||||
}, options);
|
||||
|
||||
const result = await _converse.api.archive.query(query);
|
||||
result.messages.forEach(message_handler);
|
||||
/* eslint-disable no-await-in-loop */
|
||||
for (const message of result.messages) {
|
||||
try {
|
||||
await message_handler(message);
|
||||
} catch (e) {
|
||||
_converse.log(e, Strophe.LogLevel.ERROR);
|
||||
}
|
||||
}
|
||||
|
||||
if (result.error) {
|
||||
result.error.retry = () => this.fetchArchivedMessages(options, page);
|
||||
|
Loading…
Reference in New Issue
Block a user