refactor: simpler mtask var

This commit is contained in:
VC
2022-11-07 21:25:53 +01:00
parent 3b0e7234af
commit c62f67c3b3

View File

@@ -23,13 +23,13 @@ use elefren::{prelude::*, status_builder::StatusBuilder};
use log::{debug, info};
use rusqlite::Connection;
use std::sync::Arc;
use tokio::{spawn, sync::Mutex, task::JoinHandle};
use tokio::{spawn, sync::Mutex};
/// This is where the magic happens
#[tokio::main]
pub async fn run(config: Config) {
// create the task vector for handling multiple accounts
let mut mtask: Vec<JoinHandle<()>> = vec![];
let mut mtask = vec![];
// open the SQLite connection
let conn = Arc::new(Mutex::new(