mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-17 20:13:30 +01:00
typings(CommandInteractionOptionResolver): Document & type thread channels (#6521)
This commit is contained in:
@@ -143,7 +143,7 @@ class BaseCommandInteraction extends Interaction {
|
|||||||
* subcommand (group)
|
* subcommand (group)
|
||||||
* @property {User} [user] The resolved user
|
* @property {User} [user] The resolved user
|
||||||
* @property {GuildMember|APIGuildMember} [member] The resolved member
|
* @property {GuildMember|APIGuildMember} [member] The resolved member
|
||||||
* @property {GuildChannel|APIChannel} [channel] The resolved channel
|
* @property {GuildChannel|ThreadChannel|APIChannel} [channel] The resolved channel
|
||||||
* @property {Role|APIRole} [role] The resolved role
|
* @property {Role|APIRole} [role] The resolved role
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|||||||
@@ -141,7 +141,7 @@ class CommandInteractionOptionResolver {
|
|||||||
* Gets a channel option.
|
* Gets a channel option.
|
||||||
* @param {string} name The name of the option.
|
* @param {string} name The name of the option.
|
||||||
* @param {boolean} [required=false] Whether to throw an error if the option is not found.
|
* @param {boolean} [required=false] Whether to throw an error if the option is not found.
|
||||||
* @returns {?(GuildChannel|APIGuildChannel)}
|
* @returns {?(GuildChannel|ThreadChannel|APIChannel)}
|
||||||
* The value of the option, or null if not set and not required.
|
* The value of the option, or null if not set and not required.
|
||||||
*/
|
*/
|
||||||
getChannel(name, required = false) {
|
getChannel(name, required = false) {
|
||||||
|
|||||||
2
typings/index.d.ts
vendored
2
typings/index.d.ts
vendored
@@ -3359,7 +3359,7 @@ export interface CommandInteractionOption {
|
|||||||
options?: CommandInteractionOption[];
|
options?: CommandInteractionOption[];
|
||||||
user?: User;
|
user?: User;
|
||||||
member?: GuildMember | APIInteractionDataResolvedGuildMember;
|
member?: GuildMember | APIInteractionDataResolvedGuildMember;
|
||||||
channel?: GuildChannel | APIInteractionDataResolvedChannel;
|
channel?: GuildChannel | ThreadChannel | APIInteractionDataResolvedChannel;
|
||||||
role?: Role | APIRole;
|
role?: Role | APIRole;
|
||||||
message?: Message | APIMessage;
|
message?: Message | APIMessage;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user