Skip to content

Commit

Permalink
maybe prevent double replies?
Browse files Browse the repository at this point in the history
  • Loading branch information
Techbot121 authored and Meta Construct committed Apr 8, 2024
1 parent 58fa9df commit b525a43
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/services/discord/modules/shitposting.ts
Original file line number Diff line number Diff line change
Expand Up @@ -406,6 +406,7 @@ export default async (bot: DiscordBot) => {
((isMention && msg.content !== `<@${id}>`) || isTriggerWord || isMaybeTriggerWord)
) {
if (!posting && (!replied || !isChatChannel)) {
if (isChatChannel) replied = true;
await sendShat(
msg.stickers.size > 0
? { forceImage: true, ping: true }
Expand All @@ -415,7 +416,6 @@ export default async (bot: DiscordBot) => {
ping: true,
}
).catch(console.error);
if (isChatChannel) replied = true;
data.lastMsgTime = lastMsgTime = now;
} else {
msg.react(getRandomEmoji()).catch();
Expand Down

0 comments on commit b525a43

Please sign in to comment.