mirror of
https://framagit.org/veretcle/scootaloo.git
synced 2025-07-20 17:11:19 +02:00
refactor: add info/debug
This commit is contained in:
@@ -20,7 +20,7 @@ pub use state::{init_db, migrate_db};
|
||||
use state::{read_state, write_state, TweetToToot};
|
||||
|
||||
use elefren::{prelude::*, status_builder::StatusBuilder};
|
||||
use log::{debug, info};
|
||||
use log::info;
|
||||
use rusqlite::Connection;
|
||||
use std::sync::Arc;
|
||||
use tokio::{spawn, sync::Mutex};
|
||||
@@ -48,7 +48,7 @@ pub async fn run(config: Config) {
|
||||
let task_conn = conn.clone();
|
||||
|
||||
let task = spawn(async move {
|
||||
debug!("Starting treating {}", &mastodon_config.twitter_screen_name);
|
||||
info!("Starting treating {}", &mastodon_config.twitter_screen_name);
|
||||
|
||||
// retrieve the last tweet ID for the username
|
||||
let lconn = task_conn.lock().await;
|
||||
@@ -81,7 +81,7 @@ pub async fn run(config: Config) {
|
||||
feed.reverse();
|
||||
|
||||
for tweet in &feed {
|
||||
debug!("Treating Tweet {} inside feed", tweet.id);
|
||||
info!("Treating Tweet {} inside feed", tweet.id);
|
||||
// initiate the toot_reply_id var
|
||||
let mut toot_reply_id: Option<String> = None;
|
||||
// determine if the tweet is part of a thread (response to self) or a standard response
|
||||
@@ -113,7 +113,7 @@ pub async fn run(config: Config) {
|
||||
|
||||
status_text = status_text.replace(&media_url, "");
|
||||
|
||||
debug!("Building corresponding Mastodon status");
|
||||
info!("Building corresponding Mastodon status");
|
||||
|
||||
let mut status_builder = StatusBuilder::new();
|
||||
|
||||
|
Reference in New Issue
Block a user