1
0
mirror of https://github.com/matrix-org/matrix-js-sdk.git synced 2025-11-26 17:03:12 +03:00

fix check for empty cross-signing repsonse

This commit is contained in:
Hubert Chathi
2019-05-29 16:59:51 -04:00
parent 609ee663fa
commit 941d871daf

View File

@@ -829,7 +829,11 @@ class DeviceListUpdateSerialiser {
// now do the same for the cross-signing keys
{
if (crossSigningResponse && Object.keys(crossSigningResponse).length) {
// FIXME: should we be ignoring empty cross-signing responses, or
// should we be dropping the keys?
if (crossSigningResponse
&& (crossSigningResponse.master || crossSigningResponse.self_signing
|| crossSigningResponse.user_signing)) {
const crossSigning
= this._deviceList.getStoredCrossSigningForUser(userId)
|| new CrossSigningInfo(userId);