Compare commits

...

2 Commits

Author SHA1 Message Date
6698b7c656 Merge remote-tracking branch 'origin/master'
All checks were successful
Deploy to Dokku / docker (ubuntu-latest) (push) Successful in 1m20s
2024-07-04 01:04:50 +01:00
0a80db8195 return a msg if it's not your cancel request 2024-07-04 01:04:38 +01:00
2 changed files with 3 additions and 1 deletions

View File

@ -101,7 +101,6 @@ public class RequestSubCommand extends BatSubCommand implements EventListener {
}
VoiceChannel targetChannel = targetVoiceState.getChannel().asVoiceChannel();
// User is already in the target channel
if (voiceState.getChannel().getId().equals(targetChannel.getId())) {
event.replyEmbeds(EmbedUtils.errorEmbed()

View File

@ -27,6 +27,9 @@ public class RequestListener implements EventListener {
.filter(request -> request.getMember().getId().equals(event.getUser().getId()))
.findFirst();
if (optionalDragRequest.isEmpty()) {
event.replyEmbeds(EmbedUtils.errorEmbed()
.setDescription("You do not have a request to cancel.")
.build()).queue();
return;
}
DragRequest dragRequest = optionalDragRequest.get();