Skip to content

Commit

Permalink
fix(core.gbapp): Fixing script name in call.
Browse files Browse the repository at this point in the history
  • Loading branch information
rodrigorodriguez committed Nov 22, 2020
1 parent 09b9bd8 commit 6343313
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions packages/core.gbapp/services/GBMinService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ export class GBMinService {
let startDialog = activeMin.core.getParam(activeMin.instance, 'Start Dialog', null);
GBLog.info(`Auto start dialog is now being called: ${startDialog}...`);
if (startDialog) {
req.body.messages[0].body = `/${startDialog}`;
req.body.messages[0].body = `${startDialog}`;
await (activeMin as any).whatsAppDirectLine.received(req, res);
}
else {
Expand All @@ -191,14 +191,15 @@ export class GBMinService {
`Agora falando com ${activeMin.instance.title}...`
);
let startDialog = activeMin.core.getParam(activeMin.instance, 'Start Dialog', null);
GBLog.info(`Auto start dialog is now being called: ${startDialog}...`);
if (startDialog) {
GBLog.info(`Auto start dialog is now being called: ${startDialog}...`); req.body.messages[0].body = `/${startDialog}`;
req.body.messages[0].body = `${startDialog}`;
await (activeMin as any).whatsAppDirectLine.received(req, res);
}
else {
res.end();
}
} else {
} else {
activeMin = GBServer.globals.minInstances.filter(p => p.instance.instanceId === user.instanceId)[0];
if (activeMin === undefined) {
activeMin = GBServer.globals.minBoot;
Expand Down

0 comments on commit 6343313

Please sign in to comment.