fix: don't remove message on check mark on all
channel
This commit is contained in:
parent
d9f23b544a
commit
a9eeef17d7
@ -43,6 +43,12 @@ int main()
|
|||||||
|
|
||||||
bot.on_message_reaction_add([&bot](const dpp::message_reaction_add_t& event)
|
bot.on_message_reaction_add([&bot](const dpp::message_reaction_add_t& event)
|
||||||
{
|
{
|
||||||
|
dpp::channel channel = bot.channel_get_sync(event.channel_id);
|
||||||
|
dpp::channel category = bot.channel_get_sync(channel.parent_id);
|
||||||
|
|
||||||
|
if (category.is_category() == false || category.name != GROCERY_LIST_CATEGORY)
|
||||||
|
return;
|
||||||
|
|
||||||
if (event.reacting_user.id == bot.me.id)
|
if (event.reacting_user.id == bot.me.id)
|
||||||
return;
|
return;
|
||||||
dpp::emoji emoji = event.reacting_emoji;
|
dpp::emoji emoji = event.reacting_emoji;
|
||||||
|
Loading…
Reference in New Issue
Block a user