mirror of
https://github.com/toast-ts/Daggerbot-TS.git
synced 2024-11-17 16:30:58 -05:00
99b962db2e
Half of them is untested on development bot so I wouldn't be surprised if I broke it in production.
9 lines
811 B
TypeScript
9 lines
811 B
TypeScript
import Discord from 'discord.js';
|
|
import TClient from '../client.js';
|
|
export default {
|
|
run(client:TClient, reaction:Discord.MessageReaction, user:Discord.User){
|
|
if (!client.config.botSwitches.logs || reaction.message.guildId != client.config.mainServer.id || reaction.message.partial) return;
|
|
if (reaction.emoji.name === '🖕') return (client.channels.cache.get(client.config.mainServer.channels.logs) as Discord.TextChannel).send({embeds:[new client.embed().setColor(client.config.embedColorRed).setTimestamp().setAuthor({name: `Author: ${user.username} (${user.id})`, iconURL: `${user.displayAvatarURL()}`}).setTitle('Message reaction').setDescription(`<@${user.id}>\nRemoved a reaction from the message.\n**Emoji**\n${reaction.emoji.name}\n**Channel**\n<#${reaction.message.channelId}>`)]})
|
|
}
|
|
}
|