refactor(e2ee): session management in config

This commit is contained in:
vulet 2021-02-21 19:07:56 +08:00
parent 9da2d13dbf
commit fcadc5addc
2 changed files with 5 additions and 3 deletions

View file

@ -26,6 +26,7 @@ matrixClient.on('event', async (event) => {
});
matrixClient.on('Room.timeline', async (event, member, toStartOfTimeline) => {
matrixClient.setGlobalErrorOnUnknownDevices(config.matrix.manualVerify);
if (toStartOfTimeline) return;
if (event.isEncrypted()) await event._decryptionPromise;
if (event.getType() !== 'm.room.message') return;