forked from Fascinated/Bat
ples bby gurl
This commit is contained in:
parent
11299b3ca7
commit
5e17f655a4
@ -64,10 +64,15 @@ public abstract class BatCommand {
|
||||
if (info.isUserInstall()) {
|
||||
integrationTypes.add(IntegrationType.USER_INSTALL);
|
||||
}
|
||||
List<InteractionContextType> contextTypes = new ArrayList<>();
|
||||
if (info.isGuildOnly()) {
|
||||
contextTypes.add(InteractionContextType.GUILD);
|
||||
} else {
|
||||
contextTypes.addAll(List.of(InteractionContextType.values()));
|
||||
}
|
||||
commandData = new CommandDataImpl(info.getName(), info.getDescription())
|
||||
.setContexts(InteractionContextType.ALL)
|
||||
.setIntegrationTypes(integrationTypes)
|
||||
.setGuildOnly(!getInfo().isUserInstall() && getInfo().isGuildOnly());
|
||||
.setContexts(contextTypes)
|
||||
.setIntegrationTypes(integrationTypes);
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user