Add SlaveConnection.id

Add .id property to access the id of the slave this SlaveConnection is
for.
This commit is contained in:
Hornwitser committed 2021-05-12 20:42:52 +02:00
1 parent 322570f298
commit e9c3c38a53
1 file changed
+9
+9
View File
@@ -41,6 +41,15 @@ class SlaveConnection extends BaseConnection {
}
}
/**
* ID of the slave this connection is connected to
*
* @returns {number} slave ID.
*/
get id() {
return this._id;
}
async instanceStatusChangedEventHandler(message, event) {
let instance = this._master.instances.get(message.data.instance_id);