|
|
|
@ -41,8 +41,7 @@ impl EventHandler for Handler
|
|
|
|
// events can be dispatched simultaneously.
|
|
|
|
// events can be dispatched simultaneously.
|
|
|
|
async fn message(&self, ctx: Context, msg: Message)
|
|
|
|
async fn message(&self, ctx: Context, msg: Message)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
commands::parse(ctx, msg).await;
|
|
|
|
commands::parse(ctx, msg).await;
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
async fn reaction_add(&self, ctx: Context, add_reaction: Reaction)
|
|
|
|
async fn reaction_add(&self, ctx: Context, add_reaction: Reaction)
|
|
|
|
@ -124,9 +123,9 @@ async fn main()
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
// Fetch the application owner id
|
|
|
|
// Fetch the application owner id
|
|
|
|
let http = Http::new(&token);
|
|
|
|
let http = Http::new(&token);
|
|
|
|
let owner = match http.get_current_application_info().await
|
|
|
|
let owner = match http.get_current_application_info().await
|
|
|
|
{
|
|
|
|
{
|
|
|
|
Ok(info) => info.owner.id,
|
|
|
|
Ok(info) => info.owner.id,
|
|
|
|
Err(why) => panic!("Could not access application info: {:?}", why),
|
|
|
|
Err(why) => panic!("Could not access application info: {:?}", why),
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|