2
0
mirror of https://github.com/kotatogram/kotatogram-desktop synced 2025-10-01 11:22:20 +00:00

Simplify SendProgressManager::done prototype.

This commit is contained in:
John Preston
2022-11-10 09:19:43 +04:00
parent ca460dab6d
commit b514496546
2 changed files with 3 additions and 5 deletions

View File

@@ -141,7 +141,7 @@ void SendProgressManager::send(const Key &key, int progress) {
MTP_int(key.topMsgId),
action
)).done([=](const MTPBool &result, mtpRequestId requestId) {
done(result, requestId);
done(requestId);
}).send();
_requests.emplace(key, requestId);
@@ -171,9 +171,7 @@ bool SendProgressManager::skipRequest(const Key &key) const {
}
}
void SendProgressManager::done(
const MTPBool &result,
mtpRequestId requestId) {
void SendProgressManager::done(mtpRequestId requestId) {
for (auto i = _requests.begin(), e = _requests.end(); i != e; ++i) {
if (i->second == requestId) {
_requests.erase(i);