1
0
mirror of https://github.com/matrix-org/matrix-js-sdk.git synced 2025-11-29 16:43:09 +03:00

Reset megolm session when people join/leave the room

This commit is contained in:
Richard van der Hoff
2016-08-26 11:23:01 +01:00
parent 2da70ca024
commit b4f22310ea
7 changed files with 91 additions and 14 deletions

View File

@@ -90,6 +90,13 @@ EncryptionAlgorithm.prototype.initRoomEncryption = function(roomMembers) {
* @return {module:client.Promise} Promise which resolves to the new event body
*/
/**
* Called when the membership of a member of the room changes.
*
* @param {module:models/event.MatrixEvent} event event causing the change
* @param {module:models/room-member} member user whose membership changed
*/
EncryptionAlgorithm.prototype.onRoomMembership = function(event, member) {};
/**
* base type for decryption implementations
@@ -125,7 +132,7 @@ module.exports.DecryptionAlgorithm = DecryptionAlgorithm;
*
* @method module:crypto-algorithms/base.DecryptionAlgorithm#onRoomKeyEvent
*
* @param {module:modules/event~MatrixEvent} event key event
* @param {module:models/event.MatrixEvent} event key event
*/
DecryptionAlgorithm.prototype.onRoomKeyEvent = function(params) {
// ignore by default