Add ability to register commands and events to specific environments #50
1 changed files with 2 additions and 2 deletions
|
@ -15,7 +15,7 @@ export class Util {
|
||||||
for (let command of globalCommands) {
|
for (let command of globalCommands) {
|
||||||
if (!command.Command.CommandBuilder) continue;
|
if (!command.Command.CommandBuilder) continue;
|
||||||
|
|
||||||
if ((command.Environment & CoreClient.Environment) == CoreClient.Environment) {
|
if (command.Environment &= CoreClient.Environment) {
|
||||||
globalCommandData.push(command.Command.CommandBuilder);
|
globalCommandData.push(command.Command.CommandBuilder);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -43,7 +43,7 @@ export class Util {
|
||||||
for (let command of guildCommands.filter(x => x.ServerId == guild)) {
|
for (let command of guildCommands.filter(x => x.ServerId == guild)) {
|
||||||
if (!command.Command.CommandBuilder) continue;
|
if (!command.Command.CommandBuilder) continue;
|
||||||
|
|
||||||
if ((command.Environment & CoreClient.Environment) == CoreClient.Environment) {
|
if (command.Environment &= CoreClient.Environment) {
|
||||||
guildCommandData.push(command.Command.CommandBuilder);
|
guildCommandData.push(command.Command.CommandBuilder);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue