fix(whatsapp.gblib): FIX on HEAR ON after provider change.

This commit is contained in:
rodrigorodriguez 2022-10-16 10:29:59 -03:00
parent e01bc57119
commit 916794fc15

View file

@ -473,8 +473,9 @@ export class WhatsappDirectLine extends GBService {
const botId = this.min.instance.botId;
const state = WhatsappDirectLine.state[botId + from];
if (state) {
GBLog.verbose(`BASIC: Continuing HEAR from WhatsApp...`);
WhatsappDirectLine.state[botId + from] = null;
await state.promise(null, message.text);
await state.promise(null, text);
return; // Exit here.
};