Skip empty requests for cross-signing keys when user only has one device.
Cause: Request button pressed in user settings. Result: Request body is jsNull; sendToDevice requires jsObject.
This commit is contained in:
parent
7f9af9016d
commit
0253aa59c7
@ -1613,6 +1613,9 @@ request_cross_signing_keys()
|
|||||||
body[local_user][dev] = secretRequest;
|
body[local_user][dev] = secretRequest;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (body.empty())
|
||||||
|
return;
|
||||||
|
|
||||||
http::client()->send_to_device<mtx::events::msg::SecretRequest>(
|
http::client()->send_to_device<mtx::events::msg::SecretRequest>(
|
||||||
http::client()->generate_txn_id(),
|
http::client()->generate_txn_id(),
|
||||||
body,
|
body,
|
||||||
|
Loading…
Reference in New Issue
Block a user