Fix: Pasar quoted como opción de Baileys, no dentro del content
All checks were successful
build-and-deploy / build-and-deploy (push) Successful in 1m8s
All checks were successful
build-and-deploy / build-and-deploy (push) Successful in 1m8s
El campo quoted debe ir en el tercer parámetro (opciones) de sendMessage, no dentro del objeto content. Esto corrige el envío de respuestas.
This commit is contained in:
@@ -496,13 +496,13 @@ class BaileysManager extends EventEmitter {
|
||||
/**
|
||||
* Send a message
|
||||
*/
|
||||
async sendMessage(instanceId: string, jid: string, content: any): Promise<any> {
|
||||
async sendMessage(instanceId: string, jid: string, content: any, options?: any): Promise<any> {
|
||||
const managed = this.instances.get(instanceId)
|
||||
if (!managed?.socket) {
|
||||
throw new Error('Instance not connected')
|
||||
}
|
||||
|
||||
const result = await managed.socket.sendMessage(jid, content)
|
||||
const result = await managed.socket.sendMessage(jid, content, options)
|
||||
this.emit('message.sent', { instanceId, message: result })
|
||||
return result
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user