13.1.5 debug /search command and /config only_officers_search configuration

This commit is contained in:
SowinskiBraeden committed 2022-10-25 12:21:31 -07:00
1 parent 206972b487
commit 5317e96a48
3 files changed
+10 -7

No files matched your search

+3 -4
View File
@@ -825,12 +825,11 @@ module.exports = {
}
} else if (args[0].name == 'only_officers_search') {
const setting = args[0].options[0];
client.dbo.collection("guilds").updateOne({"server.serverID":GuildDB.serverID}, {$set: {"server.onlyOfficersSearch": setting}}, function(err, res) {
client.dbo.collection("guilds").updateOne({"server.serverID":GuildDB.serverID}, {$set: {"server.onlyOfficersSearch": args[0].options[0].value}}, function(err, res) {
if (err) return client.sendInternalError(interaction, err);
});
const title = setting ? 'True: Only officers can use /search' : 'False: Any user can use /search';
let title = args[0].options[0].value ? 'True: Only officers can use /search' : 'False: Any user can use /search';
const successEmbed = new EmbedBuilder()
.setColor(client.config.Colors.Green)
@@ -838,7 +837,7 @@ module.exports = {
return interaction.send({ embeds: [successEmbed] });
} else if (args[0].name == 'casino_multiplier') {
client.dbo.collection("guilds").updateOne({"server.serverID":GuildDB.serverID}, {$set: {"server.casinoMultiplier": args[0].options[0]}}, function(err, res) {
client.dbo.collection("guilds").updateOne({"server.serverID":GuildDB.serverID}, {$set: {"server.casinoMultiplier": args[0].options[0].value}}, function(err, res) {
if (err) return client.sendInternalError(interaction, err);
});