discord.js
discord.js copied to clipboard
`SelectMenuOptionBuilder#setDescription` does not accept null or undefined values
Which package is this bug report for?
builders
Issue description
Like other constructors, making this one accept null or undefined.
Error:

Code sample
import { SelectMenuOptionBuilder } from 'discord.js';
new SelectMenuOptionBuilder()
.setDescription(null);
Package version
discord.js@^14.0.3 - @discordjs/builders@^0.14.0
Node.js version
18.6.0
Operating system
Windows 10 IoT Enterprise LTSC 21H2
Priority this issue should have
Low (slightly annoying)
Which partials do you have configured?
Not applicable (subpackage bug)
Which gateway intents are you subscribing to?
Not applicable (subpackage bug)
I have tested this issue on a development release
No response
This is also a problem with the other non-required property setters (e.g. setEmoji), also for the other components
Also SelectMenuBuilder don't have value submited when used in modal Always undefined We can't set label on it when used in modal
Also SelectMenuBuilder don't have value submited when used in modal Always undefined We can't set label on it when used in modal
SelectMenus are not supported in Modals. Discord has not announced or released the feature officially.