In a channel I choose, delete any message that replies to the author\'s own earlier message, and tell them privately to edit the original instead
Automatically deletes messages where members reply to their own earlier messages, and sends them a private reminder to edit the original message instead. This keeps conversations cleaner by preventing fragmented self-replies.
Setup: Choose which channel to monitor in the settings.
How it works: When someone replies to their own message in the monitored channel, the reply is deleted and they receive a DM explaining they should edit the original instead.
Made by MEE6. Remix it to get a copy of your own and change anything you like.
Hi! I removed your reply in #general because you were replying to your own message. Instead of replying to yourself, please edit your original message to add more information. This keeps the conversation cleaner! 😊
// Delete messages that reply to the author's own earlier message
mee6.settings({
channel: {
type: 'channel',
label: 'Channel to monitor',
required: true,
sample: 'general',
},
});
// Only messages in the configured channel wake the module
mee6.on('message', { channels: [mee6.setting('channel')] }, async (ctx) => {
// Check if this message replies to another message
if (!ctx.message.referencedMessageId) return;
// Fetch the message being replied to
const repliedTo = await mee6.getMessage(ctx.channelId, ctx.message.referencedMessageId);
if (!repliedTo) return;
// Check if the author is replying to their own message
if (repliedTo.author.id === ctx.author.id) {
// Delete the self-reply
await ctx.delete();
// Send a private message explaining why
await mee6.dm(
ctx.author.id,
`Hi! I removed your reply in <#${ctx.channelId}> because you were replying to your own message. ` +
`Instead of replying to yourself, please edit your original message to add more information. ` +
`This keeps the conversation cleaner! 😊`
);
}
});