hide non allowed channel warning messages

This commit is contained in:
SowinskiBraeden committed 2022-12-06 20:49:40 -08:00
1 parent 89b0c06cdf
commit 0b63a971da
14 files changed
+14 -14

No files matched your search

+1 -1
View File
@@ -53,7 +53,7 @@ module.exports = {
*/
run: async (client, interaction, args, { GuildDB }) => {
if (GuildDB.customChannelStatus==true&&!GuildDB.allowedChannels.includes(interaction.channel_id)) {
return interaction.send({ content: `You are not allowed to use the bot in this channel.` });
return interaction.send({ content: `You are not allowed to use the bot in this channel.`, flags: (1 << 6) });
}
const missing = !GuildDB.dispatchChannel && !GuildDB.dispatcherRole
+1 -1
View File
@@ -54,7 +54,7 @@ module.exports = {
*/
run: async (client, interaction, args, { GuildDB }) => {
if (GuildDB.customChannelStatus==true&&!GuildDB.allowedChannels.includes(interaction.channel_id)) {
return interaction.send({ content: `You are not allowed to use the bot in this channel.` });
return interaction.send({ content: `You are not allowed to use the bot in this channel.`, flags: (1 << 6) });
}
const missing = !GuildDB.dispatchChannel && !GuildDB.dispatcherRole
+1 -1
View File
@@ -111,7 +111,7 @@ module.exports = {
*/
run: async (client, interaction, args, { GuildDB }) => {
if (GuildDB.customChannelStatus==true&&!GuildDB.allowedChannels.includes(interaction.channel_id)) {
return interaction.send({ content: `You are not allowed to use the bot in this channel.` });
return interaction.send({ content: `You are not allowed to use the bot in this channel.`, flags: (1 << 6) });
}
let banking = await client.dbo.collection("banks").findOne({"banking.userID": interaction.member.user.id}).then(banking => banking);
+1 -1
View File
@@ -20,7 +20,7 @@ module.exports = {
*/
run: async (client, interaction, args, { GuildDB }) => {
if (GuildDB.customChannelStatus==true&&!GuildDB.allowedChannels.includes(interaction.channel_id)) {
return interaction.send({ content: `You are not allowed to use the bot in this channel.` });
return interaction.send({ content: `You are not allowed to use the bot in this channel.`, flags: (1 << 6) });
}
if (GuildDB.allowedChannels.length == 0) {
+1 -1
View File
@@ -38,7 +38,7 @@ module.exports = {
*/
run: async (client, interaction, args, { GuildDB }) => {
if (GuildDB.customChannelStatus==true&&!GuildDB.allowedChannels.includes(interaction.channel_id)) {
return interaction.send({ content: `You are not allowed to use the bot in this channel.` });
return interaction.send({ content: `You are not allowed to use the bot in this channel.`, flags: (1 << 6) });
}
if (!GuildDB.officerRole) {
+1 -1
View File
@@ -143,7 +143,7 @@ module.exports = {
*/
run: async (client, interaction, args, { GuildDB }) => {
if (GuildDB.customChannelStatus==true&&!GuildDB.allowedChannels.includes(interaction.channel_id)) {
return interaction.send({ content: `You are not allowed to use the bot in this channel.` });
return interaction.send({ content: `You are not allowed to use the bot in this channel.`, flags: (1 << 6) });
}
let inventory = await client.dbo.collection("inventories").findOne({"inventory.userID": interaction.member.user.id}).then(inventory => inventory);
+1 -1
View File
@@ -65,7 +65,7 @@ module.exports = {
*/
run: async (client, interaction, args, { GuildDB }) => {
if (GuildDB.customChannelStatus && !GuildDB.allowedChannels.includes(interaction.channel_id)) {
return interaction.send(`You are not allowed to use the bot in this channel.`);
return interaction.send({ content: `You are not allowed to use the bot in this channel.`, flags: (1 << 6) });
}
if (args[0].name == 'list') {
+1 -1
View File
@@ -29,7 +29,7 @@ module.exports = {
*/
run: async (client, interaction, args, { GuildDB }) => {
if (GuildDB.customChannelStatus==true&&!GuildDB.allowedChannels.includes(interaction.channel_id)) {
return interaction.send({ content: `You are not allowed to use the bot in this channel.` });
return interaction.send({ content: `You are not allowed to use the bot in this channel.`, flags: (1 << 6) });
}
const actionEmbed = new EmbedBuilder()
+1 -1
View File
@@ -37,7 +37,7 @@ module.exports = {
*/
run: async (client, interaction, args, { GuildDB }) => {
if (GuildDB.customChannelStatus==true&&!GuildDB.allowedChannels.includes(interaction.channel_id)) {
return interaction.send({ content: `You are not allowed to use the bot in this channel.` });
return interaction.send({ content: `You are not allowed to use the bot in this channel.`, flags: (1 << 6) });
}
if (GuildDB.onlyOfficersSearch && !client.exists(GuildDB.officerRole)) {
+1 -1
View File
@@ -37,7 +37,7 @@ module.exports = {
*/
run: async (client, interaction, args, { GuildDB }) => {
if (GuildDB.customChannelStatus==true&&!GuildDB.allowedChannels.includes(interaction.channel_id)) {
return interaction.send({ content: `You are not allowed to use the bot in this channel.` });
return interaction.send({ content: `You are not allowed to use the bot in this channel.`, flags: (1 << 6) });
}
const userID = interaction.member.user.id;
+1 -1
View File
@@ -58,7 +58,7 @@ module.exports = {
*/
run: async (client, interaction, args, { GuildDB }) => {
if (GuildDB.customChannelStatus==true&&!GuildDB.allowedChannels.includes(interaction.channel_id)) {
return interaction.send({ content: `You are not allowed to use the bot in this channel.` });
return interaction.send({ content: `You are not allowed to use the bot in this channel.`, flags: (1 << 6) });
}
let inventory = await client.dbo.collection("inventories").findOne({"inventory.userID": interaction.member.user.id}).then(inventory => inventory);
+1 -1
View File
@@ -21,7 +21,7 @@ module.exports = {
*/
run: async (client, interaction, args, { GuildDB }) => {
if (GuildDB.customChannelStatus==true&&!GuildDB.allowedChannels.includes(interaction.channel_id)) {
return interaction.send({ content: `You are not allowed to use the bot in this channel.` });
return interaction.send({ content: `You are not allowed to use the bot in this channel.`, flags: (1 << 6) });
}
if (GuildDB.incomeRoleStatus) {
+1 -1
View File
@@ -23,7 +23,7 @@ module.exports = {
*/
run: async (client, interaction, args, { GuildDB }) => {
if (GuildDB.customChannelStatus==true&&!GuildDB.allowedChannels.includes(interaction.channel_id)) {
return interaction.send({ content: `You are not allowed to use the bot in this channel.` });
return interaction.send({ content: `You are not allowed to use the bot in this channel.`, flags: (1 << 6) });
}
const hasWorkRole = GuildDB.incomeRoles.some(data => {
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "quarksbot",
"version": "13.2.4",
"version": "13.2.5",
"description": "Grand Theft Auto V Roleplay Bot",
"main": "index.js",
"nodemonConfig": {