Skip to content

Commit

Permalink
send
Browse files Browse the repository at this point in the history
Signed-off-by: David <[email protected]>
  • Loading branch information
DavidCraftDev committed Oct 12, 2023
1 parent 582df2e commit 8f7fa5f
Show file tree
Hide file tree
Showing 3 changed files with 25,553 additions and 10 deletions.
9 changes: 1 addition & 8 deletions command-deployment.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,4 @@ const rest = new REST().setToken(token);
{ body: commands },
);

console.log(`Successfully reloaded ${data.length} application (/) commands.`);
} catch (error) {
// And of course, make sure you catch and log any errors!
console.error(error);
}
})();

//SRC: https://github.com/discordjs/guide/blob/main/code-samples/creating-your-bot/command-deployment/deploy-commands.js
console.log(`Successf
17 changes: 15 additions & 2 deletions events/messageCreate.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,21 @@
const scam = require("../scam.json")
const teamServerClient = new WebhookClient({ id: "1162036161842258041", token: "EXZ1MzE29tI7KiPt-dTXUNkO54TPWIw7BDYHsvyf5z1JKbSgu_POjKPoYt7RdNPL8BXl" });

module.exports = {
name: "messageCreate",
async execute(message, client, config) {
if (message.channelId === BigInt(config.gh_feed)) {
async execute(message, client, config,) {
if (message.channelId === config.gh_feed) {
message.crosspost();
}
for(var i = 0; i < scam.length; i++) {
if(message.content.toLowerCase().includes(scam[i].toLowerCase())) {
message.delete();
teamServerClient.send({
content: message.author.username + ' hat folgende Nachricht gesendet die Automatisch gelöscht wurde "' + message.content + '"',
});
message.author.send("In deiner letzen Nachricht wurde ein Scam Link automatisch endeckt. Folgedesen wurde deine Nachricht gelöscht und du für eine Stunde getimeoutet. Das weitere vorgehen endscheidet das Team.")
message.guild.members.cache.find(member => member.id === message.author.id)
}
}
},
};
Loading

0 comments on commit 8f7fa5f

Please sign in to comment.