mirror of
https://github.com/cheveguerra/whatsapp-web.js.git
synced 2026-04-19 20:19:14 +00:00
add extra option to MessageSendOptions (#600)
Co-authored-by: Pedro S. Lopez <pslamoros@hotmail.com>
This commit is contained in:
2
index.d.ts
vendored
2
index.d.ts
vendored
@@ -602,6 +602,8 @@ declare namespace WAWebJS {
|
|||||||
sendSeen?: boolean
|
sendSeen?: boolean
|
||||||
/** Media to be sent */
|
/** Media to be sent */
|
||||||
media?: MessageMedia
|
media?: MessageMedia
|
||||||
|
/** Extra options */
|
||||||
|
extra?: any
|
||||||
/** Sticker name, if sendMediaAsSticker is true */
|
/** Sticker name, if sendMediaAsSticker is true */
|
||||||
stickerName?: string
|
stickerName?: string
|
||||||
/** Sticker author, if sendMediaAsSticker is true */
|
/** Sticker author, if sendMediaAsSticker is true */
|
||||||
|
|||||||
@@ -462,7 +462,8 @@ class Client extends EventEmitter {
|
|||||||
caption: options.caption,
|
caption: options.caption,
|
||||||
quotedMessageId: options.quotedMessageId,
|
quotedMessageId: options.quotedMessageId,
|
||||||
parseVCards: options.parseVCards === false ? false : true,
|
parseVCards: options.parseVCards === false ? false : true,
|
||||||
mentionedJidList: Array.isArray(options.mentions) ? options.mentions.map(contact => contact.id._serialized) : []
|
mentionedJidList: Array.isArray(options.mentions) ? options.mentions.map(contact => contact.id._serialized) : [],
|
||||||
|
...options.extra
|
||||||
};
|
};
|
||||||
|
|
||||||
const sendSeen = typeof options.sendSeen === 'undefined' ? true : options.sendSeen;
|
const sendSeen = typeof options.sendSeen === 'undefined' ? true : options.sendSeen;
|
||||||
|
|||||||
Reference in New Issue
Block a user