mirror of
https://github.com/cheveguerra/whatsapp-web.js.git
synced 2026-04-18 03:29:14 +00:00
extra options can override other options when sending message (#1103)
* Fix the option to use special options When we want to use some extra function we need to pass it into the options object, but because it inserted in the first line, the auto options reset some options (like 'type'). This is minor change that can help to add functionallity * Update Injected.js Put the special options in the end * Update Injected.js Fix , mistake * only `extra` options can override everything else Co-authored-by: Pedro Lopez <pedroslopez@me.com>
This commit is contained in:
@@ -540,7 +540,7 @@ class Client extends EventEmitter {
|
||||
quotedMessageId: options.quotedMessageId,
|
||||
parseVCards: options.parseVCards === false ? false : true,
|
||||
mentionedJidList: Array.isArray(options.mentions) ? options.mentions.map(contact => contact.id._serialized) : [],
|
||||
...options.extra
|
||||
extraOptions: options.extra
|
||||
};
|
||||
|
||||
const sendSeen = typeof options.sendSeen === 'undefined' ? true : options.sendSeen;
|
||||
|
||||
Reference in New Issue
Block a user