@indra.ai/deva 1.1.18 → 1.1.19
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 +7 -0
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -190,6 +190,13 @@ class Deva {
|
|
|
190
190
|
***************/
|
|
191
191
|
_assignInherit() {
|
|
192
192
|
return new Promise((resolve, reject) => {
|
|
193
|
+
// set the default listeners for the states of the agent.
|
|
194
|
+
for (let state in this._states) {
|
|
195
|
+
this.events.on(`${this.agent.key}:${state}`, packet => {
|
|
196
|
+
return this[state](packet);
|
|
197
|
+
})
|
|
198
|
+
}
|
|
199
|
+
|
|
193
200
|
try {
|
|
194
201
|
for (let d in this.devas) {
|
|
195
202
|
this.inherit.forEach(inherit => {
|