Formatting changes
This commit is contained in:
15
index.js
15
index.js
@@ -34,8 +34,7 @@ for (const file of cmdFiles) {
|
||||
if ('data' in cmd && 'execute' in cmd && cmd.type === 'slash') {
|
||||
client.commands.set(cmd.data.name, cmd);
|
||||
} else {
|
||||
console.log(`[WARNING] The command at ${
|
||||
filePath} is missing a required "data", "execute" or "type" property.`);
|
||||
console.log(`[WARNING] The command at ${filePath} is missing a required "data", "execute" or "type" property.`);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -52,8 +51,7 @@ for (const file of cmdTestFiles) {
|
||||
if ('data' in cmd && 'execute' in cmd && cmd.type === 'slash') {
|
||||
client.commands.set(cmd.data.name, cmd);
|
||||
} else {
|
||||
console.log(`[WARNING] The command at ${
|
||||
filePath} is missing a required "data", "execute" or "type" property.`);
|
||||
console.log(`[WARNING] The command at ${filePath} is missing a required "data", "execute" or "type" property.`);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -93,8 +91,7 @@ for (const file of contextMenuFiles) {
|
||||
if ('data' in cmd && 'execute' in cmd && cmd.type === 'contextmenu') {
|
||||
client.commands.set(cmd.data.name, cmd);
|
||||
} else {
|
||||
console.log(`[WARNING] The command at ${
|
||||
filePath} is missing a required "data", "execute" or "type" property.`);
|
||||
console.log(`[WARNING] The command at ${filePath} is missing a required "data", "execute" or "type" property.`);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -133,8 +130,7 @@ for (const file of btnFiles) {
|
||||
if ('name' in btn && 'execute' in btn && btn.type === 'button') {
|
||||
client.events.set(btn.name, btn);
|
||||
} else {
|
||||
console.log(`[WARNING] The button at ${
|
||||
filePath} is missing a required "name", "execute" or "type" property.`);
|
||||
console.log(`[WARNING] The button at ${filePath} is missing a required "name", "execute" or "type" property.`);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -174,8 +170,7 @@ for (const file of modalFiles) {
|
||||
if ('name' in modal && 'execute' in modal && modal.type === 'modal') {
|
||||
client.on(Events.InteractionCreate, modal.execute);
|
||||
} else {
|
||||
console.log(`[WARNING] The modal at ${
|
||||
filePath} is missing a required "name", "execute" or "type" property.`);
|
||||
console.log(`[WARNING] The modal at ${filePath} is missing a required "name", "execute" or "type" property.`);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user