From 8327b710bab0d26413fc475be02383bde7de3d69 Mon Sep 17 00:00:00 2001 From: "me@rodrigorodriguez.com" Date: Sun, 29 Sep 2024 22:15:39 -0300 Subject: [PATCH] fix(all): Templates OK. --- packages/core.gbapp/services/GBMinService.ts | 4 ++-- packages/whatsapp.gblib/services/WhatsappDirectLine.ts | 4 +--- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/packages/core.gbapp/services/GBMinService.ts b/packages/core.gbapp/services/GBMinService.ts index df7ee938..43cb1f20 100644 --- a/packages/core.gbapp/services/GBMinService.ts +++ b/packages/core.gbapp/services/GBMinService.ts @@ -1195,13 +1195,13 @@ export class GBMinService { } } else if (context.activity.type === 'message') { - let pid = WhatsappDirectLine.pidByNumber[user.userSystemId]; + let pid = WhatsappDirectLine.pidByNumber[context.activity.from.id]; // Required for F0 handling of persisted conversations. GBLogEx.info( min, - `Human: pid:${pid} ${context.activity.text} (type: ${context.activity.type}, name: ${context.activity.name}, channelId: ${context.activity.channelId})` + `Human: pid:${pid} ${context.activity.from.id} ${GBUtil.toYAML(WhatsappDirectLine.pidByNumber)} ${context.activity.text} (type: ${context.activity.type}, name: ${context.activity.name}, channelId: ${context.activity.channelId})` ); diff --git a/packages/whatsapp.gblib/services/WhatsappDirectLine.ts b/packages/whatsapp.gblib/services/WhatsappDirectLine.ts index 0de2e5e3..ad179d84 100644 --- a/packages/whatsapp.gblib/services/WhatsappDirectLine.ts +++ b/packages/whatsapp.gblib/services/WhatsappDirectLine.ts @@ -536,9 +536,7 @@ export class WhatsappDirectLine extends GBService { let response; if (GBConfigService.get('STORAGE_NAME')) { response = await client.apis.Conversations.Conversations_StartConversation( - { userSystemId: user.userSystemId, - userName: user.userName, - pid: pid} + ); } else { response = await client.apis.Conversations.Conversations_StartConversation(