Merge branch 'develop' into gsouquet/switch-rooms

This commit is contained in:
Germain Souquet 2021-05-27 10:22:16 +01:00
commit 51d88062f9
10 changed files with 559 additions and 418 deletions

View file

@ -176,7 +176,8 @@ export class MessagePreviewStore extends AsyncStoreWithClient<IState> {
if (payload.action === 'MatrixActions.Room.timeline' || payload.action === 'MatrixActions.Event.decrypted') {
const event = payload.event; // TODO: Type out the dispatcher
if (!this.previews.has(event.getRoomId()) || !event.isLiveEvent) return; // not important
const isHistoricalEvent = payload.hasOwnProperty("isLiveEvent") && !payload.isLiveEvent
if (!this.previews.has(event.getRoomId()) || isHistoricalEvent) return; // not important
await this.generatePreview(this.matrixClient.getRoom(event.getRoomId()), TAG_ANY);
}
}