mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-19 13:03:31 +01:00
fix: poll builders (#10783)
* fix: poll builders
- Fixed validations
- Added missing documentation
- Removed redundant code
- Consistency™️
* fix: tests
* feat: missing answers test
This commit is contained in:
@@ -161,7 +161,7 @@ export class PollBuilder implements JSONEncodable<RESTAPIPoll> {
|
||||
* @param updater - The function to update the question with
|
||||
*/
|
||||
public updateQuestion(updater: (builder: PollQuestionBuilder) => void): this {
|
||||
updater((this.data.question ??= new PollQuestionBuilder()));
|
||||
updater(this.data.question);
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user