forked from Sarah/Lieb-Website
added choosen answer to poll feedback
This commit is contained in:
parent
9e3eaebb3d
commit
eaa0b4c4ef
3 changed files with 6 additions and 3 deletions
|
@ -74,7 +74,8 @@ namespace DiscordBot.CommandHandlers
|
|||
UserId = component.User.Id
|
||||
};
|
||||
await _httpService.AnswerPoll(answer);
|
||||
await component.RespondAsync("Answer sent.", ephemeral: true);
|
||||
ButtonComponent usedButton = (ButtonComponent)component.Message.Components.First().Components.First(c => c.CustomId == component.Data.CustomId);
|
||||
await component.RespondAsync($"Answer \"{usedButton.Label}\" sent.", ephemeral: true);
|
||||
break;
|
||||
case Constants.ComponentIds.POLL_CUSTOM_ANSWER_BUTTON:
|
||||
PollMessage.Parameters pollCustomParameters = PollMessage.ParseId(component.Data.CustomId);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue