Remove SSSS requests on the UI thread

might fix #656
This commit is contained in:
Nicolas Werner 2021-07-25 15:39:49 +02:00
parent 8b3d0c14d0
commit 80b9d4528e
No known key found for this signature in database
GPG Key ID: C8D75E610773F2D9
1 changed files with 4 additions and 1 deletions

View File

@ -1406,9 +1406,12 @@ request_cross_signing_keys()
body,
[request_id = secretRequest.request_id, secretName](mtx::http::RequestErr err) {
if (err) {
request_id_to_secret_name.erase(request_id);
nhlog::net()->error("Failed to send request for secrect '{}'",
secretName);
// Cancel request on UI thread
QTimer::singleShot(1, cache::client(), [request_id]() {
request_id_to_secret_name.erase(request_id);
});
return;
}
});