mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-17 03:53:29 +01:00
docs: update outdated examples (#8081)
This commit is contained in:
@@ -48,12 +48,12 @@ class GuildStickerManager extends CachedManager {
|
|||||||
* @returns {Promise<Sticker>} The created sticker
|
* @returns {Promise<Sticker>} The created sticker
|
||||||
* @example
|
* @example
|
||||||
* // Create a new sticker from a URL
|
* // Create a new sticker from a URL
|
||||||
* guild.stickers.create('https://i.imgur.com/w3duR07.png', 'rip', 'headstone')
|
* guild.stickers.create({ file: 'https://i.imgur.com/w3duR07.png', name: 'rip', tags: 'headstone' })
|
||||||
* .then(sticker => console.log(`Created new sticker with name ${sticker.name}!`))
|
* .then(sticker => console.log(`Created new sticker with name ${sticker.name}!`))
|
||||||
* .catch(console.error);
|
* .catch(console.error);
|
||||||
* @example
|
* @example
|
||||||
* // Create a new sticker from a file on your computer
|
* // Create a new sticker from a file on your computer
|
||||||
* guild.stickers.create('./memes/banana.png', 'banana', 'banana')
|
* guild.stickers.create({ file: './memes/banana.png', name: 'banana', tags: 'banana' })
|
||||||
* .then(sticker => console.log(`Created new sticker with name ${sticker.name}!`))
|
* .then(sticker => console.log(`Created new sticker with name ${sticker.name}!`))
|
||||||
* .catch(console.error);
|
* .catch(console.error);
|
||||||
*/
|
*/
|
||||||
|
|||||||
@@ -356,7 +356,8 @@ class TextBasedChannel {
|
|||||||
* @returns {Promise<Webhook>} Returns the created Webhook
|
* @returns {Promise<Webhook>} Returns the created Webhook
|
||||||
* @example
|
* @example
|
||||||
* // Create a webhook for the current channel
|
* // Create a webhook for the current channel
|
||||||
* channel.createWebhook('Snek', {
|
* channel.createWebhook({
|
||||||
|
* name: 'Snek',
|
||||||
* avatar: 'https://i.imgur.com/mI8XcpG.jpg',
|
* avatar: 'https://i.imgur.com/mI8XcpG.jpg',
|
||||||
* reason: 'Needed a cool new Webhook'
|
* reason: 'Needed a cool new Webhook'
|
||||||
* })
|
* })
|
||||||
|
|||||||
Reference in New Issue
Block a user