Skip to content

Commit cc70f41

Browse files
committed
iequidoo's review: Rename get_statistics_bot() -> get_statistics_chat_id()
1 parent 0e1b10a commit cc70f41

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/statistics.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ pub(crate) async fn should_send_statistics(context: &Context) -> Result<bool> {
196196
async fn send_statistics(context: &Context) -> Result<ChatId> {
197197
info!(context, "Sending statistics.");
198198

199-
let chat_id = get_statistics_bot(context).await?;
199+
let chat_id = get_statistics_chat_id(context).await?;
200200

201201
let mut msg = Message::new(Viewtype::File);
202202
msg.set_text(
@@ -320,7 +320,7 @@ async fn get_statistics(context: &Context) -> Result<String> {
320320
Ok(serde_json::to_string_pretty(&statistics)?)
321321
}
322322

323-
async fn get_statistics_bot(context: &Context) -> Result<ChatId, anyhow::Error> {
323+
async fn get_statistics_chat_id(context: &Context) -> Result<ChatId, anyhow::Error> {
324324
let contact_id: ContactId = *import_vcard(context, STATISTICS_BOT_VCARD)
325325
.await?
326326
.first()
@@ -465,7 +465,7 @@ async fn get_message_stats(
465465
"Last_msgid < 9 would mean including 'special' messages in the statistics"
466466
);
467467

468-
let statistics_bot_chat_id = get_statistics_bot(context).await?;
468+
let statistics_bot_chat_id = get_statistics_chat_id(context).await?;
469469

470470
let trans_fn = |t: &mut rusqlite::Transaction| {
471471
t.pragma_update(None, "query_only", "0")?;

0 commit comments

Comments
 (0)