mirror of
https://github.com/darksaid98/cadence-discord-bot.git
synced 2026-12-04 14:38:49 +00:00
feat!: Sharding implemented across the bot
This commit is contained in:
1 parent
b160cbf564
commit
9c15c636d9
29 files changed
+270
-142
No files matched your search
@@ -33,7 +33,7 @@ module.exports = {
|
||||
if (skipToTrack) {
|
||||
if (skipToTrack > queue.tracks.data.length) {
|
||||
logger.debug(
|
||||
`User used command ${interaction.commandName} but track number was higher than total tracks.`
|
||||
`[Shard ${interaction.guild.shardId}] User used command ${interaction.commandName} but track number was higher than total tracks.`
|
||||
);
|
||||
return await interaction.editReply({
|
||||
embeds: [
|
||||
@@ -52,7 +52,9 @@ module.exports = {
|
||||
: `\`${skippedTrack.duration}\``;
|
||||
queue.node.skipTo(skipToTrack - 1);
|
||||
|
||||
logger.debug(`User used command ${interaction.commandName} and skipped to track.`);
|
||||
logger.debug(
|
||||
`[Shard ${interaction.guild.shardId}] User used command ${interaction.commandName} and skipped to track.`
|
||||
);
|
||||
return await interaction.editReply({
|
||||
embeds: [
|
||||
new EmbedBuilder()
|
||||
@@ -71,7 +73,7 @@ module.exports = {
|
||||
} else {
|
||||
if (queue.tracks.data.length === 0 && !queue.currentTrack) {
|
||||
logger.debug(
|
||||
`User used command ${interaction.commandName} but there was no tracks in queue or current track.`
|
||||
`[Shard ${interaction.guild.shardId}] User used command ${interaction.commandName} but there was no tracks in queue or current track.`
|
||||
);
|
||||
return await interaction.editReply({
|
||||
embeds: [
|
||||
@@ -100,7 +102,9 @@ module.exports = {
|
||||
|
||||
const loopModeUserString = loopModesFormatted.get(queue.repeatMode);
|
||||
|
||||
logger.debug(`User used command ${interaction.commandName} and skipped track.`);
|
||||
logger.debug(
|
||||
`[Shard ${interaction.guild.shardId}] User used command ${interaction.commandName} and skipped track.`
|
||||
);
|
||||
return await interaction.editReply({
|
||||
embeds: [
|
||||
new EmbedBuilder()
|
||||
|
||||
Reference in new issue
Block a user