Commit 9b5ec5aa authored by tec's avatar tec

Ignore bot reactions, but care about bot messages

parent f991ed61
......@@ -89,7 +89,7 @@ impl EventHandler for Handler {
fn reaction_add(&self, ctx: Context, add_reaction: channel::Reaction) {
match add_reaction.message(&ctx.http) {
Ok(message) => {
if message.author.id.0 == config::BOT_ID {
if message.author.id.0 != config::BOT_ID || add_reaction.user_id == config::BOT_ID {
return;
}
match message_type(&message) {
......@@ -106,7 +106,7 @@ impl EventHandler for Handler {
fn reaction_remove(&self, ctx: Context, removed_reaction: channel::Reaction) {
match removed_reaction.message(&ctx.http) {
Ok(message) => {
if message.author.id.0 == config::BOT_ID {
if message.author.id.0 != config::BOT_ID || removed_reaction.user_id == config::BOT_ID {
return;
}
match message_type(&message) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment