Skip to content

Commit f03ffe1

Browse files
committed
Fix singular usages of "statistics".
1 parent e58847a commit f03ffe1

File tree

4 files changed

+7
-7
lines changed

4 files changed

+7
-7
lines changed

‎memprof/memprof_stat.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ static std::atomic<std::size_t> total_memory_used;
4141
void register_xalloc(malloc_info *info, std::int32_t diff) {
4242
my_assert(info->size >= 0);
4343
// TODO: this is very slow in case of several threads.
44-
// Currently this statistics is intended only for memory benchmarks.
44+
// Currently, the statistics are intended only for memory benchmarks.
4545
total_memory_used.fetch_add(diff * info->size, std::memory_order_relaxed);
4646
}
4747

‎td/telegram/ContactsManager.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -8451,7 +8451,7 @@ void ContactsManager::get_channel_statistics_dc_id_impl(ChannelId channel_id, bo
84518451
}
84528452

84538453
if (!channel_full->stats_dc_id.is_exact() || (for_full_statistics && !channel_full->can_view_statistics)) {
8454-
return promise.set_error(Status::Error(400, "Chat statistics is not available"));
8454+
return promise.set_error(Status::Error(400, "Chat statistics are not available"));
84558455
}
84568456

84578457
promise.set_value(DcId(channel_full->stats_dc_id));

‎td/telegram/StatisticsManager.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -417,7 +417,7 @@ void StatisticsManager::send_get_channel_message_stats_query(
417417
return promise.set_error(Status::Error(400, "Message not found"));
418418
}
419419
if (!td_->messages_manager_->can_get_message_statistics(message_full_id)) {
420-
return promise.set_error(Status::Error(400, "Message statistics is inaccessible"));
420+
return promise.set_error(Status::Error(400, "Message statistics are inaccessible"));
421421
}
422422
CHECK(dialog_id.get_type() == DialogType::Channel);
423423
td_->create_handler<GetMessageStatsQuery>(std::move(promise))

‎td/telegram/Td.cpp

+4-4
Original file line numberDiff line numberDiff line change
@@ -4964,10 +4964,10 @@ void Td::on_request(uint64 id, td_api::optimizeStorage &request) {
49644964

49654965
void Td::on_request(uint64 id, td_api::getNetworkStatistics &request) {
49664966
if (net_stats_manager_.empty()) {
4967-
return send_error_raw(id, 400, "Network statistics is disabled");
4967+
return send_error_raw(id, 400, "Network statistics are disabled");
49684968
}
49694969
if (!request.only_current_ && G()->get_option_boolean("disable_persistent_network_statistics")) {
4970-
return send_error_raw(id, 400, "Persistent network statistics is disabled");
4970+
return send_error_raw(id, 400, "Persistent network statistics are disabled");
49714971
}
49724972
CREATE_REQUEST_PROMISE();
49734973
auto query_promise = PromiseCreator::lambda([promise = std::move(promise)](Result<NetworkStats> result) mutable {
@@ -4983,7 +4983,7 @@ void Td::on_request(uint64 id, td_api::getNetworkStatistics &request) {
49834983

49844984
void Td::on_request(uint64 id, td_api::resetNetworkStatistics &request) {
49854985
if (net_stats_manager_.empty()) {
4986-
return send_error_raw(id, 400, "Network statistics is disabled");
4986+
return send_error_raw(id, 400, "Network statistics are disabled");
49874987
}
49884988
CREATE_OK_REQUEST_PROMISE();
49894989
send_closure(net_stats_manager_, &NetStatsManager::reset_network_stats);
@@ -4995,7 +4995,7 @@ void Td::on_request(uint64 id, td_api::addNetworkStatistics &request) {
49954995
return send_error_raw(id, 400, "Network statistics entry must be non-empty");
49964996
}
49974997
if (net_stats_manager_.empty()) {
4998-
return send_error_raw(id, 400, "Network statistics is disabled");
4998+
return send_error_raw(id, 400, "Network statistics are disabled");
49994999
}
50005000

50015001
NetworkStatsEntry entry;

0 commit comments

Comments
 (0)