You've already forked matrix-js-sdk
mirror of
https://github.com/matrix-org/matrix-js-sdk.git
synced 2025-11-25 05:23:13 +03:00
lint
This commit is contained in:
committed by
Travis Ralston
parent
549656884b
commit
8c72fd104e
@@ -888,7 +888,9 @@ OlmDevice.prototype.addInboundGroupSession = async function(
|
||||
<= session.first_known_index()) {
|
||||
// existing session has lower index (i.e. can
|
||||
// decrypt more), so keep it
|
||||
logger.log(`Keeping existing megolm session ${sessionId}`);
|
||||
logger.log(
|
||||
`Keeping existing megolm session ${sessionId}`,
|
||||
);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -200,7 +200,8 @@ MegolmEncryption.prototype._ensureOutboundSession = function(devicesInRoom) {
|
||||
if (!session) {
|
||||
logger.log(`Starting new megolm session for room ${self._roomId}`);
|
||||
session = await self._prepareNewSession();
|
||||
logger.log(`Started new megolm session ${session.sessionId} for room ${self._roomId}`);
|
||||
logger.log(`Started new megolm session ${session.sessionId} ` +
|
||||
`for room ${self._roomId}`);
|
||||
self._outboundSessions[session.sessionId] = session;
|
||||
}
|
||||
|
||||
@@ -441,13 +442,13 @@ MegolmEncryption.prototype.reshareKeyWithDevice = async function(
|
||||
) {
|
||||
const obSessionInfo = this._outboundSessions[sessionId];
|
||||
if (!obSessionInfo) {
|
||||
logger.debug("megolm session ID " + sessionId + " not found: not re-sharing keys");
|
||||
logger.debug(`megolm session ${sessionId} not found: not re-sharing keys`);
|
||||
return;
|
||||
}
|
||||
|
||||
// The chain index of the key we previously sent this device
|
||||
if (obSessionInfo.sharedWithDevices[userId] === undefined) {
|
||||
logger.debug("megolm session ID " + sessionId + " never shared with user " + userId);
|
||||
logger.debug(`megolm session ${sessionId} never shared with user ${userId}`);
|
||||
return;
|
||||
}
|
||||
const sentChainIndex = obSessionInfo.sharedWithDevices[userId][device.deviceId];
|
||||
@@ -467,7 +468,7 @@ MegolmEncryption.prototype.reshareKeyWithDevice = async function(
|
||||
|
||||
if (!key) {
|
||||
logger.warn(
|
||||
"No inbound session key found for megolm " + sessionId + ": not re-sharing keys",
|
||||
`No inbound session key found for megolm ${sessionId}: not re-sharing keys`,
|
||||
);
|
||||
return;
|
||||
}
|
||||
@@ -514,9 +515,8 @@ MegolmEncryption.prototype.reshareKeyWithDevice = async function(
|
||||
[device.deviceId]: encryptedContent,
|
||||
},
|
||||
});
|
||||
logger.debug(
|
||||
`Re-shared key for megolm session ${sessionId} with ${userId}:${device.deviceId}`,
|
||||
);
|
||||
logger.debug(`Re-shared key for megolm session ${sessionId} ` +
|
||||
`with ${userId}:${device.deviceId}`);
|
||||
};
|
||||
|
||||
/**
|
||||
|
||||
@@ -2277,7 +2277,8 @@ Crypto.prototype._getTrackedE2eRooms = function() {
|
||||
|
||||
Crypto.prototype._onToDeviceEvent = function(event) {
|
||||
try {
|
||||
console.log(`received to_device ${event.getType()} from: ${event.getSender()} id: ${event.getId()}`);
|
||||
console.log(`received to_device ${event.getType()} from: ` +
|
||||
`${event.getSender()} id: ${event.getId()}`);
|
||||
|
||||
if (event.getType() == "m.room_key"
|
||||
|| event.getType() == "m.forwarded_room_key") {
|
||||
|
||||
Reference in New Issue
Block a user