Use a more correct subset of users in `/remakeolm` developer command (#9402)

pull/28217/head
Travis Ralston 2022-10-12 13:28:30 -04:00 committed by GitHub
parent 7cb2f941d3
commit 7b55b89ac6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 3 deletions

View File

@ -1104,12 +1104,13 @@ export const Commands = [
MatrixClientPeg.get().forceDiscardSession(roomId); MatrixClientPeg.get().forceDiscardSession(roomId);
// noinspection JSIgnoredPromiseFromCall return success(room.getEncryptionTargetMembers().then(members => {
MatrixClientPeg.get().crypto.ensureOlmSessionsForUsers(room.getMembers().map(m => m.userId), true); // noinspection JSIgnoredPromiseFromCall
MatrixClientPeg.get().crypto.ensureOlmSessionsForUsers(members.map(m => m.userId), true);
}));
} catch (e) { } catch (e) {
return reject(e.message); return reject(e.message);
} }
return success();
}, },
category: CommandCategories.advanced, category: CommandCategories.advanced,
renderingTypes: [TimelineRenderingType.Room], renderingTypes: [TimelineRenderingType.Room],