mirror of
https://github.com/EvolutionAPI/evolution-api.git
synced 2025-07-26 02:18:38 -06:00
test
This commit is contained in:
parent
7bc4c7b36e
commit
17ecc88f80
@ -936,7 +936,10 @@ export class BaileysStartupService extends WAStartupService {
|
|||||||
) => {
|
) => {
|
||||||
try {
|
try {
|
||||||
this.logger.verbose('Event received: messages.upsert');
|
this.logger.verbose('Event received: messages.upsert');
|
||||||
for (const received of messages) {
|
|
||||||
|
const received = messages[0];
|
||||||
|
|
||||||
|
// for (const received of messages) {
|
||||||
if (
|
if (
|
||||||
(type !== 'notify' && type !== 'append') ||
|
(type !== 'notify' && type !== 'append') ||
|
||||||
received.message?.protocolMessage ||
|
received.message?.protocolMessage ||
|
||||||
@ -964,7 +967,7 @@ export class BaileysStartupService extends WAStartupService {
|
|||||||
received?.message?.documentMessage ||
|
received?.message?.documentMessage ||
|
||||||
received?.message?.audioMessage;
|
received?.message?.audioMessage;
|
||||||
|
|
||||||
const contentMsg = received.message[getContentType(received.message)] as any;
|
const contentMsg = received?.message[getContentType(received.message)] as any;
|
||||||
|
|
||||||
if (this.localWebhook.webhook_base64 === true && isMedia) {
|
if (this.localWebhook.webhook_base64 === true && isMedia) {
|
||||||
const buffer = await downloadMediaMessage(
|
const buffer = await downloadMediaMessage(
|
||||||
@ -1106,7 +1109,7 @@ export class BaileysStartupService extends WAStartupService {
|
|||||||
|
|
||||||
this.logger.verbose('Inserting contact in database');
|
this.logger.verbose('Inserting contact in database');
|
||||||
this.repository.contact.insert([contactRaw], this.instance.name, database.SAVE_DATA.CONTACTS);
|
this.repository.contact.insert([contactRaw], this.instance.name, database.SAVE_DATA.CONTACTS);
|
||||||
}
|
// }
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
this.logger.error(error);
|
this.logger.error(error);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user