SlashCommandStringOption.addChoices() quesiton #7825
-
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 5 replies
-
In that version, just pass in an object to addChoices ( |
Beta Was this translation helpful? Give feedback.
-
This is very bad timing to be answering this but here we go... In the current 0.13.0 release of builders the add/set methods take rest parameters. That is, as many objects as you like NOT in an array, separated by commas. The next release, and currently in main/dev release, it has been changed to an array (the way you attempted) because... well, it's the way people naturally attempt to and expect to use these methods. |
Beta Was this translation helpful? Give feedback.
In that version, just pass in an object to addChoices (
.addChoices({ name, value })
), but in a future version the array you mentioned will be the correct way of using the method