Merge branch 'soru/cancel-broadcast-verify' into 'main'

fix: Allow to broadcast cancels during key verification

See merge request famedly/famedlysdk!643
This commit is contained in:
Krille Fear 2021-02-10 12:44:21 +00:00
commit 6d7ab8e1d4
1 changed files with 4 additions and 1 deletions

View File

@ -602,7 +602,10 @@ class KeyVerification {
} else { } else {
Logs().i('[Key Verification] Sending to ${userId} device ${deviceId}...'); Logs().i('[Key Verification] Sending to ${userId} device ${deviceId}...');
if (deviceId == '*') { if (deviceId == '*') {
if ({EventTypes.KeyVerificationRequest}.contains(type)) { if ({
EventTypes.KeyVerificationRequest,
EventTypes.KeyVerificationCancel,
}.contains(type)) {
await client.sendToDevicesOfUserIds({userId}, type, payload); await client.sendToDevicesOfUserIds({userId}, type, payload);
} else { } else {
Logs().e( Logs().e(