Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
rakshithx09 committed Oct 29, 2023
1 parent bbf1973 commit f730512
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { Client, GatewayIntentBits, Events, Partials } from "discord.js";
import getAvatar from "./avatar.js";

const anonymousChannel = process.env.ANONUMOUS_CHANNEL;
const roleName = process.env.ROLE_NAME;
const roleName= "stealth-admin";
const modChannel = process.env.MOD_CHANNEL;
const token = process.env.DISCORD_TOKEN;
if (!anonymousChannel || !token) {
Expand Down Expand Up @@ -37,7 +37,7 @@ client.on(Events.MessageCreate, async (message) => {
}

if (channel.id !== anonymousChannel) return;
if (roleName && message.member.roles.cache.some((role) => role.name === roleName)) return; // admin can't send anonymous messages
if (message.member.roles.cache.some((role) => role.name === roleName)) return; // admin can't send anonymous messages
await channelMessage(channel, message, messageStamp);
});

Expand Down

0 comments on commit f730512

Please sign in to comment.