mirror of
https://github.com/EvolutionAPI/evolution-api.git
synced 2025-07-14 09:51:24 -06:00
fix: Fixed problem with fileSha256 appearing when sending a sticker in chatwoot
This commit is contained in:
parent
a73d5f4b4d
commit
2f3d6f7e63
@ -11,6 +11,7 @@
|
|||||||
### Fixed
|
### Fixed
|
||||||
|
|
||||||
* Added link preview option in send text message
|
* Added link preview option in send text message
|
||||||
|
* Fixed problem with fileSha256 appearing when sending a sticker in chatwoot
|
||||||
|
|
||||||
### Integrations
|
### Integrations
|
||||||
|
|
||||||
|
@ -446,7 +446,7 @@ export const whatsappNumberSchema: JSONSchema7 = {
|
|||||||
uniqueItems: true,
|
uniqueItems: true,
|
||||||
items: {
|
items: {
|
||||||
type: 'string',
|
type: 'string',
|
||||||
pattern: '^\\d+',
|
// pattern: '^\\d+',
|
||||||
description: '"numbers" must be an array of numeric strings',
|
description: '"numbers" must be an array of numeric strings',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
@ -1173,6 +1173,10 @@ export class ChatwootService {
|
|||||||
|
|
||||||
const result = typeKey ? types[typeKey] : undefined;
|
const result = typeKey ? types[typeKey] : undefined;
|
||||||
|
|
||||||
|
if (typeKey === 'stickerMessage') {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
if (typeKey === 'contactMessage') {
|
if (typeKey === 'contactMessage') {
|
||||||
const vCardData = result.split('\n');
|
const vCardData = result.split('\n');
|
||||||
const contactInfo = {};
|
const contactInfo = {};
|
||||||
@ -1295,6 +1299,8 @@ export class ChatwootService {
|
|||||||
this.logger.verbose('get conversation message');
|
this.logger.verbose('get conversation message');
|
||||||
const bodyMessage = await this.getConversationMessage(body.message);
|
const bodyMessage = await this.getConversationMessage(body.message);
|
||||||
|
|
||||||
|
console.log('bodyMessage', bodyMessage, body.message);
|
||||||
|
|
||||||
if (!bodyMessage && !isMedia) {
|
if (!bodyMessage && !isMedia) {
|
||||||
this.logger.warn('no body message found');
|
this.logger.warn('no body message found');
|
||||||
return;
|
return;
|
||||||
|
@ -1335,9 +1335,14 @@ export class WAStartupService {
|
|||||||
|
|
||||||
if (settings?.msg_call.trim().length > 0 && call.status == 'offer') {
|
if (settings?.msg_call.trim().length > 0 && call.status == 'offer') {
|
||||||
this.logger.verbose('Sending message in call');
|
this.logger.verbose('Sending message in call');
|
||||||
this.client.sendMessage(call.from, {
|
const msg = await this.client.sendMessage(call.from, {
|
||||||
text: settings.msg_call,
|
text: settings.msg_call,
|
||||||
});
|
});
|
||||||
|
|
||||||
|
this.client.ev.emit('messages.upsert', {
|
||||||
|
messages: [msg],
|
||||||
|
type: 'notify',
|
||||||
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user