diff --git a/azalea/examples/echo.rs b/azalea/examples/echo.rs index 01390982..38c5d801 100755 --- a/azalea/examples/echo.rs +++ b/azalea/examples/echo.rs @@ -5,7 +5,7 @@ use azalea::prelude::*; #[tokio::main] async fn main() { let account = Account::offline("bot"); - // or let account = Account::microsoft("email").await.unwrap(); + let account = Account::microsoft("email").await.unwrap(); ClientBuilder::new() .set_handler(handle) diff --git a/azalea/src/swarm/mod.rs b/azalea/src/swarm/mod.rs index ca947579..6d3885ef 100644 --- a/azalea/src/swarm/mod.rs +++ b/azalea/src/swarm/mod.rs @@ -317,6 +317,8 @@ where let (bots_tx, mut bots_rx) = mpsc::unbounded_channel(); let (swarm_tx, mut swarm_rx) = mpsc::unbounded_channel(); + swarm_tx.send(SwarmEvent::Init).unwrap(); + let (run_schedule_sender, run_schedule_receiver) = mpsc::unbounded_channel(); let main_schedule_label = self.app.main_schedule_label; @@ -377,6 +379,8 @@ where ) .await; } + + swarm_tx.send(SwarmEvent::Login).unwrap(); }); let swarm_state = self.swarm_state;