Compare commits

...

2 Commits

Author SHA1 Message Date
a39dfb7d6e fix? 2021-09-15 18:26:29 -07:00
351dcee051 update launch.json 2021-09-15 18:21:29 -07:00
2 changed files with 2 additions and 2 deletions

2
.vscode/launch.json vendored
View File

@ -11,7 +11,7 @@
"skipFiles": [ "skipFiles": [
"<node_internals>/**" "<node_internals>/**"
], ],
"program": "${workspaceFolder}\\main.js", "program": "${workspaceFolder}\\index.js",
"envFile": "${workspaceFolder}\\secrets.env" "envFile": "${workspaceFolder}\\secrets.env"
} }
] ]

View File

@ -65,7 +65,7 @@ client.once("ready", async () => {
let guild = client.guilds.resolve(config.guild); let guild = client.guilds.resolve(config.guild);
await guild.commands.set(commands); await guild.commands.set(commands);
await guild.commands.permissions.set({ await guild.commands.permissions.set({
fullPermissions: commands.filter(x=>x.permissions).map(local_command => { fullPermissions: commands.map(local_command => {
let discord_command = guild.commands.cache.find(discord_command => local_command.name == discord_command.name); let discord_command = guild.commands.cache.find(discord_command => local_command.name == discord_command.name);
return { return {
id: discord_command.id, id: discord_command.id,