fix(all): CHART and IMAGE from GET HTTP calls.

This commit is contained in:
Rodrigo Rodriguez 2022-07-06 15:01:58 -03:00
parent 1de4683541
commit a3e99bb553

View file

@ -839,7 +839,9 @@ export class DialogKeywords {
} else {
GBLog.info(`BASIC: Sending the file ${filename} to mobile ${mobile}.`);
const url = urlJoin(
let url;
if (!filename.startsWith("https://")) {
url = urlJoin(
GBServer.globals.publicAddress,
'kb',
`${this.min.botId}.gbai`,
@ -847,6 +849,10 @@ export class DialogKeywords {
'assets',
filename
);
}
else {
url = filename;
}
await this.min.conversationalService.sendFile(this.min, step, mobile, url, caption);
}