[AB-xxx] fixing using wrong parameter for unSuggest command

This commit is contained in:
Sheldan
2023-11-15 01:06:30 +01:00
parent 60d2c669a2
commit 1ba8219d7b

View File

@@ -48,7 +48,7 @@ public class UnSuggest extends AbstractConditionableCommand {
@Override
public CompletableFuture<CommandResult> executeSlash(SlashCommandInteractionEvent event) {
Long suggestionId = slashCommandParameterService.getCommandOption(SUGGESTION_ID_PARAMETER, event, Long.class, Integer.class).longValue();
return suggestionService.removeSuggestion(event.getMember().getIdLong(), suggestionId, event.getMember())
return suggestionService.removeSuggestion(event.getGuild().getIdLong(), suggestionId, event.getMember())
.thenCompose(unused -> interactionService.replyEmbed(UN_SUGGEST_RESPONSE, event))
.thenApply(aVoid -> CommandResult.fromSuccess());
}