mirror of
https://github.com/darksaid98/cadence-discord-bot.git
synced 2026-12-02 14:38:49 +00:00
feat!: Added new config system with config npm package
This commit is contained in:
1 parent
5434df7ecf
commit
2da7cb360a
38 files changed
+146
-63
No files matched your search
+2
-3
@@ -1,8 +1,7 @@
|
||||
/node_modules
|
||||
/config.json
|
||||
/src/config.js
|
||||
/.env
|
||||
/app-*.log
|
||||
/config/*.js
|
||||
!/config/default.js
|
||||
/logs
|
||||
/logs/app-*.log
|
||||
/cookies.json
|
||||
|
||||
@@ -1,17 +1,15 @@
|
||||
const { ActivityType, PresenceUpdateStatus } = require('discord.js');
|
||||
// Description: Config file for Cadence Discord bot.
|
||||
|
||||
// General options for information about the bot.
|
||||
// General metadata about the bot displayed in certain embeds.
|
||||
module.exports.botOptions = {
|
||||
name: 'Cadence',
|
||||
websiteUrl: 'Unknown',
|
||||
botInviteUrl: 'Unknown',
|
||||
serverInviteUrl: 'Unknown'
|
||||
botInviteUrl: '',
|
||||
serverInviteUrl: ''
|
||||
};
|
||||
|
||||
// Sharding options for the bot.
|
||||
// See https://old.discordjs.dev/#/docs/discord.js/main/typedef/ShardingManagerOptions for valid options.
|
||||
// Do not change if you don't know what you are doing.
|
||||
// Configuration for bot sharding. Refers to splitting a Discord bot into multiple processes.
|
||||
// For more information, refer to Discord.js sharding documentation: https://discordjs.guide/sharding/
|
||||
module.exports.shardingOptions = {
|
||||
totalShards: 'auto',
|
||||
shardList: 'auto',
|
||||
@@ -19,24 +17,24 @@ module.exports.shardingOptions = {
|
||||
respawn: true
|
||||
};
|
||||
|
||||
// Logging options for the bot, can set logging level to file and console separately.
|
||||
// Configuration for logging bot actions.
|
||||
// You can set logging level to file and console separately.
|
||||
module.exports.loggerOptions = {
|
||||
minimumLogLevel: 'debug',
|
||||
minimumLogLevelConsole: 'info'
|
||||
};
|
||||
|
||||
// systemGuildIds: Array of guild ids where system commands should be available.
|
||||
// systemMessageChannelId: Channel id where system messages should be sent, such as error events.
|
||||
// systemUserId: User id of the system administrator, used for pining on certain system messages.
|
||||
// Options for identifying specific system command.
|
||||
module.exports.systemOptions = {
|
||||
systemGuildIds: ['Guild id where system commands can be used'],
|
||||
systemMessageChannelId: 'Channel id where system messages will be sent',
|
||||
systemUserId: 'User id of the system administrator which will receive pings on certain system messages'
|
||||
// List of guild IDs where system commands can be executed. e.g. ['123456789012345678', '123456789012345678']
|
||||
systemGuildIds: [],
|
||||
// Channel for sending system messages, such as bot errors and disconnect events. e.g. '123456789012345678'
|
||||
systemMessageChannelId: '',
|
||||
// Bot administrator user ID for specific notifications through mentions in system channel. e.g. '123456789012345678'
|
||||
systemUserId: ''
|
||||
};
|
||||
|
||||
// Options for presence/activity status. You can change from watching to listening, playing, etc.
|
||||
// See https://discord-api-types.dev/api/discord-api-types-v10/enum/ActivityType for valid activity types.
|
||||
// See https://discord-api-types.dev/api/discord-api-types-v10/enum/PresenceUpdateStatus for valid presence status.
|
||||
// Configuration for the bot's presence and activity status.
|
||||
module.exports.presenceStatusOptions = {
|
||||
status: PresenceUpdateStatus.Online,
|
||||
activities: [
|
||||
@@ -47,7 +45,8 @@ module.exports.presenceStatusOptions = {
|
||||
]
|
||||
};
|
||||
|
||||
// Options for embed messages, like colors and custom emojis.
|
||||
// Configurations for visual embed messages.
|
||||
// Includes design elements like colors and custom emojis/symbols.
|
||||
module.exports.embedOptions = {
|
||||
colors: {
|
||||
success: '#23A55A',
|
||||
@@ -101,14 +100,14 @@ module.exports.embedOptions = {
|
||||
}
|
||||
};
|
||||
|
||||
// Options for the discord-player player.
|
||||
// Configuration for the audio player. Includes behavior upon various events and UI components.
|
||||
module.exports.playerOptions = {
|
||||
leaveOnEmpty: true,
|
||||
leaveOnEmptyCooldown: 300_000,
|
||||
leaveOnEmptyCooldown: 1_800_000,
|
||||
leaveOnEnd: true,
|
||||
leaveOnEndCooldown: 300_000,
|
||||
leaveonEndCooldown: 1_800_000,
|
||||
leaveOnStop: true,
|
||||
leaveOnStopCooldown: 300_000,
|
||||
leaveOnStopCooldown: 1_800_000,
|
||||
defaultVolume: 50,
|
||||
maxQueueSize: 10_000,
|
||||
maxHistorySize: 100,
|
||||
@@ -124,7 +123,7 @@ module.exports.playerOptions = {
|
||||
}
|
||||
};
|
||||
|
||||
// Options to be used by the ffmpeg, and available ffmpeg filters shown in filter commands.
|
||||
// Configuration for ffmpeg filters for audio processing.
|
||||
module.exports.ffmpegFilterOptions = {
|
||||
threadAmount: '2',
|
||||
availableFilters: [
|
||||
@@ -185,7 +184,8 @@ module.exports.ffmpegFilterOptions = {
|
||||
]
|
||||
};
|
||||
|
||||
// Options for load testing the bot. If enabled, the bot will join the specified channels and play specified track source.
|
||||
// Configuration for load testing. Enables the bot to simulate certain behaviors for testing purposes.
|
||||
// If enabled, the bot will join the specified channels and play specified track.
|
||||
module.exports.loadTestOptions = {
|
||||
enabled: false,
|
||||
trackUrl: 'https://www.youtube.com/watch?v=tTR4D9h3zAE',
|
||||
Generated
+23
@@ -13,6 +13,7 @@
|
||||
"@discord-player/opus": "^0.1.1",
|
||||
"@discordjs/rest": "^2.0.0",
|
||||
"@distube/ytdl-core": "^4.11.17",
|
||||
"config": "^3.3.9",
|
||||
"discord-player": "^6.6.3-dev.0",
|
||||
"discord-voip": "^0.1.2",
|
||||
"discord.js": "^14.12.1",
|
||||
@@ -852,6 +853,17 @@
|
||||
"integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==",
|
||||
"devOptional": true
|
||||
},
|
||||
"node_modules/config": {
|
||||
"version": "3.3.9",
|
||||
"resolved": "https://registry.npmjs.org/config/-/config-3.3.9.tgz",
|
||||
"integrity": "sha512-G17nfe+cY7kR0wVpc49NCYvNtelm/pPy8czHoFkAgtV1lkmcp7DHtWCdDu+C9Z7gb2WVqa9Tm3uF9aKaPbCfhg==",
|
||||
"dependencies": {
|
||||
"json5": "^2.2.3"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">= 10.0.0"
|
||||
}
|
||||
},
|
||||
"node_modules/console-control-strings": {
|
||||
"version": "1.1.0",
|
||||
"resolved": "https://registry.npmjs.org/console-control-strings/-/console-control-strings-1.1.0.tgz",
|
||||
@@ -1861,6 +1873,17 @@
|
||||
"integrity": "sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==",
|
||||
"dev": true
|
||||
},
|
||||
"node_modules/json5": {
|
||||
"version": "2.2.3",
|
||||
"resolved": "https://registry.npmjs.org/json5/-/json5-2.2.3.tgz",
|
||||
"integrity": "sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg==",
|
||||
"bin": {
|
||||
"json5": "lib/cli.js"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=6"
|
||||
}
|
||||
},
|
||||
"node_modules/levn": {
|
||||
"version": "0.4.1",
|
||||
"resolved": "https://registry.npmjs.org/levn/-/levn-0.4.1.tgz",
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
"@discord-player/opus": "^0.1.1",
|
||||
"@discordjs/rest": "^2.0.0",
|
||||
"@distube/ytdl-core": "^4.11.17",
|
||||
"config": "^3.3.9",
|
||||
"discord-player": "^6.6.3-dev.0",
|
||||
"discord-voip": "^0.1.2",
|
||||
"discord.js": "^14.12.1",
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
const { embedOptions, botOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const botOptions = config.get('botOptions');
|
||||
const { SlashCommandBuilder, EmbedBuilder } = require('discord.js');
|
||||
|
||||
module.exports = {
|
||||
@@ -25,14 +27,21 @@ module.exports = {
|
||||
|
||||
const commandListString = commandList.join('\n');
|
||||
|
||||
const supportServerString = botOptions.serverInviteUrl
|
||||
? `${embedOptions.icons.support} **Support server**\nJoin the support server for help or to suggest improvements: \n**${botOptions.serverInviteUrl}**\n\n`
|
||||
: '';
|
||||
const addBotString = botOptions.botInviteUrl
|
||||
? `${embedOptions.icons.bot} **Enjoying ${botOptions.name}?**\nAdd me to another server: \n**[Click me!](${botOptions.botInviteUrl})**`
|
||||
: '';
|
||||
|
||||
return await interaction.editReply({
|
||||
embeds: [
|
||||
new EmbedBuilder()
|
||||
.setDescription(
|
||||
`${embedOptions.icons.rule} **List of commands**\n` +
|
||||
`${commandListString}\n\n` +
|
||||
`${embedOptions.icons.support} **Support server**\nJoin the support server for help or to suggest improvements: \n**${botOptions.serverInviteUrl}**\n\n` +
|
||||
`${embedOptions.icons.bot} **Enjoying ${botOptions.name}?**\nAdd me to another server: \n**[Click me!](${botOptions.botInviteUrl})**`
|
||||
supportServerString +
|
||||
addBotString
|
||||
)
|
||||
.setColor(embedOptions.colors.info)
|
||||
]
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const { getUptimeFormatted } = require('../../utils/system/getUptimeFormatted');
|
||||
const { SlashCommandBuilder, EmbedBuilder } = require('discord.js');
|
||||
const osu = require('node-os-utils');
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions, ffmpegFilterOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const ffmpegFilterOptions = config.get('ffmpegFilterOptions');
|
||||
const { notInVoiceChannel, notInSameVoiceChannel } = require('../../utils/validation/voiceChannelValidator');
|
||||
const { queueDoesNotExist, queueNoCurrentTrack } = require('../../utils/validation/queueValidator');
|
||||
const {
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const { notInVoiceChannel, notInSameVoiceChannel } = require('../../utils/validation/voiceChannelValidator');
|
||||
const { SlashCommandBuilder, EmbedBuilder } = require('discord.js');
|
||||
const { useQueue } = require('discord-player');
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions, botOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const botOptions = config.get('botOptions');
|
||||
const { notInVoiceChannel, notInSameVoiceChannel } = require('../../utils/validation/voiceChannelValidator');
|
||||
const { queueDoesNotExist } = require('../../utils/validation/queueValidator');
|
||||
const { SlashCommandBuilder, EmbedBuilder } = require('discord.js');
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const { notInVoiceChannel, notInSameVoiceChannel } = require('../../utils/validation/voiceChannelValidator');
|
||||
const { queueDoesNotExist, queueNoCurrentTrack } = require('../../utils/validation/queueValidator');
|
||||
const { SlashCommandBuilder, EmbedBuilder } = require('discord.js');
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions, playerOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const playerOptions = config.get('playerOptions');
|
||||
const { notInVoiceChannel, notInSameVoiceChannel } = require('../../utils/validation/voiceChannelValidator');
|
||||
const { queueDoesNotExist, queueNoCurrentTrack } = require('../../utils/validation/queueValidator');
|
||||
const { SlashCommandBuilder, EmbedBuilder, ActionRowBuilder, ButtonBuilder } = require('discord.js');
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const { notInVoiceChannel, notInSameVoiceChannel } = require('../../utils/validation/voiceChannelValidator');
|
||||
const { queueDoesNotExist, queueNoCurrentTrack } = require('../../utils/validation/queueValidator');
|
||||
const { SlashCommandBuilder, EmbedBuilder } = require('discord.js');
|
||||
|
||||
@@ -1,5 +1,8 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions, playerOptions, botOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const botOptions = config.get('botOptions');
|
||||
const playerOptions = config.get('playerOptions');
|
||||
const { notInVoiceChannel, notInSameVoiceChannel } = require('../../utils/validation/voiceChannelValidator');
|
||||
const { cannotJoinVoiceOrTalk } = require('../../utils/validation/permissionValidator');
|
||||
const { transformQuery } = require('../../utils/validation/searchQueryValidator');
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions, playerOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const playerOptions = config.get('playerOptions');
|
||||
const { notInVoiceChannel, notInSameVoiceChannel } = require('../../utils/validation/voiceChannelValidator');
|
||||
const { SlashCommandBuilder, EmbedBuilder } = require('discord.js');
|
||||
const { useQueue } = require('discord-player');
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const { notInVoiceChannel, notInSameVoiceChannel } = require('../../utils/validation/voiceChannelValidator');
|
||||
const { queueDoesNotExist } = require('../../utils/validation/queueValidator');
|
||||
const { SlashCommandBuilder, EmbedBuilder } = require('discord.js');
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const { notInVoiceChannel, notInSameVoiceChannel } = require('../../utils/validation/voiceChannelValidator');
|
||||
const { queueDoesNotExist, queueNoCurrentTrack } = require('../../utils/validation/queueValidator');
|
||||
const { SlashCommandBuilder, EmbedBuilder } = require('discord.js');
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const { notInVoiceChannel, notInSameVoiceChannel } = require('../../utils/validation/voiceChannelValidator');
|
||||
const { queueDoesNotExist, queueIsEmpty } = require('../../utils/validation/queueValidator');
|
||||
const { SlashCommandBuilder, EmbedBuilder } = require('discord.js');
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const { notInVoiceChannel, notInSameVoiceChannel } = require('../../utils/validation/voiceChannelValidator');
|
||||
const { queueDoesNotExist, queueNoCurrentTrack } = require('../../utils/validation/queueValidator');
|
||||
const { SlashCommandBuilder, EmbedBuilder } = require('discord.js');
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const { notInVoiceChannel, notInSameVoiceChannel } = require('../../utils/validation/voiceChannelValidator');
|
||||
const { SlashCommandBuilder, EmbedBuilder } = require('discord.js');
|
||||
const { useQueue } = require('discord-player');
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const { notInVoiceChannel, notInSameVoiceChannel } = require('../../utils/validation/voiceChannelValidator');
|
||||
const { queueDoesNotExist } = require('../../utils/validation/queueValidator');
|
||||
const { SlashCommandBuilder, EmbedBuilder } = require('discord.js');
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const { notValidGuildId } = require('../../utils/validation/systemCommandValidator');
|
||||
const { SlashCommandBuilder, EmbedBuilder } = require('discord.js');
|
||||
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const { notValidGuildId } = require('../../utils/validation/systemCommandValidator');
|
||||
const { SlashCommandBuilder, EmbedBuilder } = require('discord.js');
|
||||
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const { notValidGuildId } = require('../../utils/validation/systemCommandValidator');
|
||||
const { getUptimeFormatted } = require('../../utils/system/getUptimeFormatted');
|
||||
const { SlashCommandBuilder, EmbedBuilder } = require('discord.js');
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions, systemOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const systemOptions = config.get('systemOptions');
|
||||
const { EmbedBuilder } = require('discord.js');
|
||||
|
||||
module.exports = {
|
||||
|
||||
@@ -1,5 +1,9 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions, systemOptions, presenceStatusOptions, loadTestOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const systemOptions = config.get('systemOptions');
|
||||
const presenceStatusOptions = config.get('presenceStatusOptions');
|
||||
const loadTestOptions = config.get('loadTestOptions');
|
||||
const { postBotStats } = require('../../utils/other/postBotStats.js');
|
||||
const { startLoadTest } = require('../../utils/other/startLoadTest');
|
||||
const { Events, EmbedBuilder } = require('discord.js');
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions, systemOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const systemOptions = config.get('systemOptions');
|
||||
const { EmbedBuilder } = require('discord.js');
|
||||
|
||||
module.exports = {
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions, botOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const botOptions = config.get('botOptions');
|
||||
const { cannotSendMessageInChannel } = require('../../utils/validation/permissionValidator');
|
||||
const { Events, EmbedBuilder } = require('discord.js');
|
||||
|
||||
|
||||
@@ -1,5 +1,8 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions, systemOptions, botOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const botOptions = config.get('botOptions');
|
||||
const systemOptions = config.get('systemOptions');
|
||||
const { EmbedBuilder } = require('discord.js');
|
||||
|
||||
// Emitted when the player queue encounters error (general error with queue)
|
||||
|
||||
@@ -1,5 +1,8 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions, systemOptions, botOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const botOptions = config.get('botOptions');
|
||||
const systemOptions = config.get('systemOptions');
|
||||
const { EmbedBuilder } = require('discord.js');
|
||||
|
||||
// Emitted when the player encounters an error while streaming audio track
|
||||
|
||||
@@ -1,5 +1,8 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions, systemOptions, botOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const botOptions = config.get('botOptions');
|
||||
const systemOptions = config.get('systemOptions');
|
||||
const { EmbedBuilder } = require('discord.js');
|
||||
|
||||
// Emitted when the audio player fails to load the stream for a track
|
||||
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
require('dotenv').config();
|
||||
const { shardingOptions } = require('./config');
|
||||
const shardingOptions = require('config').get('shardingOptions');
|
||||
const logger = require('./services/logger');
|
||||
const { ShardingManager, ShardEvents } = require('discord.js');
|
||||
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
const pino = require('pino');
|
||||
const { loggerOptions } = require('../config');
|
||||
const config = require('config');
|
||||
const loggerOptions = config.get('loggerOptions');
|
||||
|
||||
const targets = [
|
||||
{
|
||||
|
||||
@@ -3,7 +3,8 @@ const logger = require('../services/logger');
|
||||
const fs = require('node:fs');
|
||||
const path = require('node:path');
|
||||
const { REST, Routes } = require('discord.js');
|
||||
const { systemOptions } = require('../config');
|
||||
const config = require('config');
|
||||
const systemOptions = config.get('systemOptions');
|
||||
|
||||
const slashCommands = [];
|
||||
const systemCommands = [];
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { loadTestOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const loadTestOptions = config.get('loadTestOptions');
|
||||
|
||||
exports.startLoadTest = async (client) => {
|
||||
if (!loadTestOptions.enabled) {
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const { EmbedBuilder } = require('discord.js');
|
||||
|
||||
exports.cannotJoinVoiceOrTalk = async (interaction) => {
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const { EmbedBuilder } = require('discord.js');
|
||||
|
||||
exports.queueDoesNotExist = async (interaction, queue) => {
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
const { embedOptions, systemOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const systemOptions = config.get('systemOptions');
|
||||
const { EmbedBuilder } = require('discord.js');
|
||||
|
||||
exports.notValidGuildId = async (interaction) => {
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
const logger = require('../../services/logger');
|
||||
const { embedOptions } = require('../../config');
|
||||
const config = require('config');
|
||||
const embedOptions = config.get('embedOptions');
|
||||
const { EmbedBuilder } = require('discord.js');
|
||||
|
||||
exports.notInVoiceChannel = async (interaction) => {
|
||||
|
||||
Reference in new issue
Block a user