Mark requests const if appropriate.
This commit is contained in:
parent
7609306ac8
commit
d5d9dabe7d
@ -4254,7 +4254,7 @@ void Td::on_request(uint64 id, const td_api::getCurrentState &request) {
|
|||||||
send_result(id, td_api::make_object<td_api::updates>(std::move(updates)));
|
send_result(id, td_api::make_object<td_api::updates>(std::move(updates)));
|
||||||
}
|
}
|
||||||
|
|
||||||
void Td::on_request(uint64 id, td_api::getPasswordState &request) {
|
void Td::on_request(uint64 id, const td_api::getPasswordState &request) {
|
||||||
CHECK_IS_USER();
|
CHECK_IS_USER();
|
||||||
CREATE_REQUEST_PROMISE();
|
CREATE_REQUEST_PROMISE();
|
||||||
send_closure(password_manager_, &PasswordManager::get_state, std::move(promise));
|
send_closure(password_manager_, &PasswordManager::get_state, std::move(promise));
|
||||||
@ -4786,7 +4786,7 @@ void Td::on_request(uint64 id, td_api::getStorageStatisticsFast &request) {
|
|||||||
});
|
});
|
||||||
send_closure(storage_manager_, &StorageManager::get_storage_stats_fast, std::move(query_promise));
|
send_closure(storage_manager_, &StorageManager::get_storage_stats_fast, std::move(query_promise));
|
||||||
}
|
}
|
||||||
void Td::on_request(uint64 id, td_api::getDatabaseStatistics &request) {
|
void Td::on_request(uint64 id, const td_api::getDatabaseStatistics &request) {
|
||||||
CREATE_REQUEST_PROMISE();
|
CREATE_REQUEST_PROMISE();
|
||||||
auto query_promise = PromiseCreator::lambda([promise = std::move(promise)](Result<DatabaseStats> result) mutable {
|
auto query_promise = PromiseCreator::lambda([promise = std::move(promise)](Result<DatabaseStats> result) mutable {
|
||||||
if (result.is_error()) {
|
if (result.is_error()) {
|
||||||
@ -7491,7 +7491,7 @@ void Td::on_request(uint64 id, const td_api::getSuggestedFileName &request) {
|
|||||||
send_closure(actor_id(this), &Td::send_result, id, td_api::make_object<td_api::text>(r_file_name.ok()));
|
send_closure(actor_id(this), &Td::send_result, id, td_api::make_object<td_api::text>(r_file_name.ok()));
|
||||||
}
|
}
|
||||||
|
|
||||||
void Td::on_request(uint64 id, td_api::preliminaryUploadFile &request) {
|
void Td::on_request(uint64 id, const td_api::preliminaryUploadFile &request) {
|
||||||
auto priority = request.priority_;
|
auto priority = request.priority_;
|
||||||
if (!(1 <= priority && priority <= 32)) {
|
if (!(1 <= priority && priority <= 32)) {
|
||||||
return send_error_raw(id, 400, "Upload priority must be between 1 and 32");
|
return send_error_raw(id, 400, "Upload priority must be between 1 and 32");
|
||||||
|
@ -525,7 +525,7 @@ class Td final : public Actor {
|
|||||||
|
|
||||||
void on_request(uint64 id, const td_api::getCurrentState &request);
|
void on_request(uint64 id, const td_api::getCurrentState &request);
|
||||||
|
|
||||||
void on_request(uint64 id, td_api::getPasswordState &request);
|
void on_request(uint64 id, const td_api::getPasswordState &request);
|
||||||
|
|
||||||
void on_request(uint64 id, td_api::setPassword &request);
|
void on_request(uint64 id, td_api::setPassword &request);
|
||||||
|
|
||||||
@ -675,7 +675,7 @@ class Td final : public Actor {
|
|||||||
|
|
||||||
void on_request(uint64 id, td_api::getStorageStatisticsFast &request);
|
void on_request(uint64 id, td_api::getStorageStatisticsFast &request);
|
||||||
|
|
||||||
void on_request(uint64 id, td_api::getDatabaseStatistics &request);
|
void on_request(uint64 id, const td_api::getDatabaseStatistics &request);
|
||||||
|
|
||||||
void on_request(uint64 id, td_api::optimizeStorage &request);
|
void on_request(uint64 id, td_api::optimizeStorage &request);
|
||||||
|
|
||||||
@ -1335,7 +1335,7 @@ class Td final : public Actor {
|
|||||||
|
|
||||||
void on_request(uint64 id, const td_api::getSuggestedFileName &request);
|
void on_request(uint64 id, const td_api::getSuggestedFileName &request);
|
||||||
|
|
||||||
void on_request(uint64 id, td_api::preliminaryUploadFile &request);
|
void on_request(uint64 id, const td_api::preliminaryUploadFile &request);
|
||||||
|
|
||||||
void on_request(uint64 id, const td_api::cancelPreliminaryUploadFile &request);
|
void on_request(uint64 id, const td_api::cancelPreliminaryUploadFile &request);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user