Skip to content

Commit

Permalink
types: Disallow some channel types from webhook creation (#8535)
Browse files Browse the repository at this point in the history
  • Loading branch information
Jiralite committed Aug 22, 2022
1 parent 526ea74 commit 10b12cc
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/managers/GuildChannelManager.js
Expand Up @@ -175,7 +175,7 @@ class GuildChannelManager extends CachedManager {

/**
* Creates a webhook for the channel.
* @param {GuildChannelResolvable} channel The channel to create the webhook for
* @param {TextChannel|NewsChannel|VoiceChannel|Snowflake} channel The channel to create the webhook for
* @param {string} name The name of the webhook
* @param {ChannelWebhookCreateOptions} [options] Options for creating the webhook
* @returns {Promise<Webhook>} Returns the created Webhook
Expand Down
2 changes: 1 addition & 1 deletion typings/index.d.ts
Expand Up @@ -3229,7 +3229,7 @@ export class GuildChannelManager extends CachedManager<Snowflake, GuildBasedChan
public createWebhook(
channel: GuildChannelResolvable,
name: string,
options?: ChannelWebhookCreateOptions,
options?: TextChannel | NewsChannel | VoiceChannel | Snowflake,
): Promise<Webhook>;
public edit(channel: GuildChannelResolvable, data: ChannelData, reason?: string): Promise<GuildChannel>;
public fetch(id: Snowflake, options?: BaseFetchOptions): Promise<NonThreadGuildBasedChannel | null>;
Expand Down

0 comments on commit 10b12cc

Please sign in to comment.