mirror of
https://github.com/vector-im/hydrogen-web.git
synced 2024-12-22 19:14:52 +01:00
log verifying senders in own item
This commit is contained in:
parent
2582600249
commit
dfede83c0b
@ -309,15 +309,16 @@ export class Room extends BaseRoom {
|
||||
promises.push(this._roomEncryption.flushPendingRoomKeyShares(this._hsApi, null, log));
|
||||
}
|
||||
if (shouldFetchUnverifiedSenders) {
|
||||
const promise = (async () => {
|
||||
const promise = log.wrap("verify senders", (async log => {
|
||||
const newlyVerifiedDecryption = await decryption.fetchAndVerifyRemainingSenders(this._hsApi, log);
|
||||
const verifiedEntries = [];
|
||||
const updateCallback = entry => verifiedEntries.push(entry);
|
||||
newlyVerifiedDecryption.applyToEntries(newEntries, updateCallback);
|
||||
newlyVerifiedDecryption.applyToEntries(updatedEntries, updateCallback);
|
||||
log.set("verifiedEntries", verifiedEntries.length);
|
||||
this._timeline?.replaceEntries(verifiedEntries);
|
||||
this._observedEvents?.updateEvents(verifiedEntries);
|
||||
});
|
||||
}));
|
||||
promises.push(promise);
|
||||
}
|
||||
await Promise.all(promises);
|
||||
|
Loading…
Reference in New Issue
Block a user