Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(WelcomeChannel): Add forum channel as a type #8643

Merged
merged 2 commits into from
Sep 21, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/discord.js/src/structures/Guild.js
Expand Up @@ -831,7 +831,7 @@ class Guild extends AnonymousGuild {
* Welcome channel data
* @typedef {Object} WelcomeChannelData
* @property {string} description The description to show for this welcome channel
* @property {GuildTextChannelResolvable} channel The channel to link for this welcome channel
* @property {TextChannel|NewsChannel|ForumChannel|Snowflake} channel The channel to link for this welcome channel
* @property {EmojiIdentifierResolvable} [emoji] The emoji to display for this welcome channel
*/

Expand Down
2 changes: 1 addition & 1 deletion packages/discord.js/src/structures/WelcomeChannel.js
Expand Up @@ -42,7 +42,7 @@ class WelcomeChannel extends Base {

/**
* The channel of this welcome channel
* @type {?(TextChannel|NewsChannel)}
* @type {?(TextChannel|NewsChannel|ForumChannel)}
*/
get channel() {
return this.client.channels.resolve(this.channelId);
Expand Down
4 changes: 2 additions & 2 deletions packages/discord.js/typings/index.d.ts
Expand Up @@ -3050,7 +3050,7 @@ export class WelcomeChannel extends Base {
public channelId: Snowflake;
public guild: Guild | InviteGuild;
public description: string;
public get channel(): TextChannel | NewsChannel | null;
public get channel(): TextChannel | NewsChannel | ForumChannel | null;
public get emoji(): GuildEmoji | Emoji;
}

Expand Down Expand Up @@ -5738,7 +5738,7 @@ export interface WidgetChannel {

export interface WelcomeChannelData {
description: string;
channel: GuildTextChannelResolvable;
channel: TextChannel | NewsChannel | ForumChannel | Snowflake;
emoji?: EmojiIdentifierResolvable;
}

Expand Down