mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-16 03:23:29 +01:00
feat(Webhook): add ability to change channel and specify reason to edit (#3587)
* feat(Webhook): add ability to change channel and specify reason to edit * fix(RESTMethods): update channelID of the webhook too
This commit is contained in:
9
typings/index.d.ts
vendored
9
typings/index.d.ts
vendored
@@ -1579,7 +1579,8 @@ declare module 'discord.js' {
|
||||
public owner: User | object;
|
||||
public token: string;
|
||||
public delete(reason?: string): Promise<void>;
|
||||
public edit(name: string, avatar: BufferResolvable): Promise<Webhook>;
|
||||
public edit(name?: string, avatar?: BufferResolvable): Promise<Webhook>;
|
||||
public edit(options?: WebhookEditOptions, reason?: string): Promise<Webhook>;
|
||||
public send(content?: StringResolvable, options?: WebhookMessageOptions | RichEmbed | Attachment): Promise<Message | Message[]>;
|
||||
public send(options?: WebhookMessageOptions | RichEmbed | Attachment): Promise<Message | Message[]>;
|
||||
public sendCode(lang: string, content: StringResolvable, options?: WebhookMessageOptions): Promise<Message | Message[]>;
|
||||
@@ -2201,6 +2202,12 @@ declare module 'discord.js' {
|
||||
|
||||
type VoiceStatus = number;
|
||||
|
||||
type WebhookEditOptions = {
|
||||
name?: string;
|
||||
avatar?: BufferResolvable;
|
||||
channel?: ChannelResolvable;
|
||||
};
|
||||
|
||||
type WebhookMessageOptions = {
|
||||
username?: string;
|
||||
avatarURL?: string;
|
||||
|
||||
Reference in New Issue
Block a user