@indra.ai/deva 1.1.33 → 1.1.34
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.js +10 -2
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -1428,6 +1428,10 @@ class Deva {
|
|
|
1428
1428
|
this.state('deva_load');
|
|
1429
1429
|
this.devas[key].init(client).then(loaded => {
|
|
1430
1430
|
this.state('deva_loaded');
|
|
1431
|
+
this.talk(`deva:load`, {
|
|
1432
|
+
key,
|
|
1433
|
+
created: Date.now(),
|
|
1434
|
+
});
|
|
1431
1435
|
return resolve();
|
|
1432
1436
|
}).catch(err => {
|
|
1433
1437
|
return this.error(err, deva, reject);
|
|
@@ -1442,10 +1446,14 @@ class Deva {
|
|
|
1442
1446
|
- deva: The deva key to unload
|
|
1443
1447
|
describe: Unload a currently loaded Deva.
|
|
1444
1448
|
***************/
|
|
1445
|
-
unload(
|
|
1449
|
+
unload(key) {
|
|
1446
1450
|
this.state('deva_unload');
|
|
1447
|
-
delete this.devas[
|
|
1451
|
+
delete this.devas[key];
|
|
1448
1452
|
this.state('deva_unloaded');
|
|
1453
|
+
this.talk(`deva:unload`, {
|
|
1454
|
+
key,
|
|
1455
|
+
created: Date.now(),
|
|
1456
|
+
});
|
|
1449
1457
|
return Promise.resolve(`unload:${deva} `);
|
|
1450
1458
|
}
|
|
1451
1459
|
|