- FIX: Whastapp line now can be turned off;

- FIX: More error logging on BuildMin.
This commit is contained in:
Rodrigo Rodriguez 2018-05-27 18:15:33 -03:00
parent 70a9862d01
commit 81a1445a09
6 changed files with 19 additions and 8 deletions

View file

@ -1,5 +1,11 @@
# Release History
## Version 0.0.25
- FIX: Whastapp line now can be turned off;
- FIX: More error logging on BuildMin.
## Version 0.0.24
- FIX: AskDialog compilation error.

View file

@ -107,15 +107,16 @@ export class GBCoreService implements IGBCoreService {
}
syncDatabaseStructure(cb) {
if (GBConfigService.get("DATABASE_SYNC")) {
if (GBConfigService.get("DATABASE_SYNC") === "true") {
logger.trace("Syncing database...");
this.sequelize.sync().then(value => {
logger.trace("Database synced.");
cb();
});
}
else{
else {
logger.trace("Database synchronization is disabled.");
cb();
}
}

View file

@ -462,6 +462,7 @@ export class GBMinService {
});
});
} catch (err) {
logger.error(err);
reject(err)
}
});

View file

@ -54,8 +54,13 @@ export class GBWhatsappPackage implements IGBPackage {
}
loadBot(min: GBMinInstance): void {
this.channel = new WhatsappDirectLine(min.botId, min.instance.whatsappBotKey, min.instance.whatsappServiceKey,
min.instance.whatsappServiceNumber, min.instance.whatsappServiceUrl, min.instance.whatsappServiceWebhookUrl);
// Only loads engine if it is defined on services.json.
if (min.instance.whatsappBotKey != "") {
this.channel = new WhatsappDirectLine(min.botId, min.instance.whatsappBotKey, min.instance.whatsappServiceKey,
min.instance.whatsappServiceNumber, min.instance.whatsappServiceUrl, min.instance.whatsappServiceWebhookUrl);
}
}
unloadBot(min: GBMinInstance): void {

View file

@ -1,6 +1,6 @@
{
"name": "botserver",
"version": "0.0.24",
"version": "0.0.25",
"description": "General Bot Community Edition open-core server.",
"contributors": [
"Rodrigo Rodriguez <me@rodrigorodriguez.com>"

View file

@ -103,7 +103,6 @@ export class GBServer {
logger.trace(`Loading sys package: ${e.name}...`);
let p = Object.create(e.prototype) as IGBPackage;
p.loadPackage(core, core.sequelize);
});
(async () => {
@ -115,9 +114,8 @@ export class GBServer {
logger.info(`Instance loaded: ${instance.botId}...`);
}, server, appPackages);
} catch (err) {
logger.log(err)
logger.info(err);
}
})()