cleanup
This commit is contained in:
@ -34,9 +34,8 @@ public class RemoveSubCommand extends BatCommand {
|
||||
@Override
|
||||
public void execute(BatGuild guild, @NonNull BatUser user, @NonNull MessageChannel channel, Member member, @NonNull SlashCommandInteraction event) {
|
||||
OptionMapping typeOption = event.getOption("type");
|
||||
if (typeOption == null) {
|
||||
return;
|
||||
}
|
||||
assert typeOption != null;
|
||||
|
||||
String type = typeOption.getAsString();
|
||||
LogProfile profile = guild.getLogProfile();
|
||||
|
||||
|
@ -38,13 +38,10 @@ public class SetSubCommand extends BatCommand {
|
||||
@Override
|
||||
public void execute(BatGuild guild, @NonNull BatUser user, @NonNull MessageChannel channel, Member member, @NonNull SlashCommandInteraction event) {
|
||||
OptionMapping typeOption = event.getOption("type");
|
||||
if (typeOption == null) {
|
||||
return;
|
||||
}
|
||||
assert typeOption != null;
|
||||
OptionMapping channelOption = event.getOption("channel");
|
||||
if (channelOption == null) {
|
||||
return;
|
||||
}
|
||||
assert channelOption != null;
|
||||
|
||||
String type = typeOption.getAsString();
|
||||
TextChannel targetChannel = channelOption.getAsChannel().asTextChannel();
|
||||
LogProfile profile = guild.getLogProfile();
|
||||
|
Reference in New Issue
Block a user