mirror of
https://github.com/clusterio/clusterio.git
synced 2026-11-15 07:24:52 +09:00
Add .id shorthand to InstanceInfo
Turn instance.config.get("instance.id") into instance.id.
This commit is contained in:
1 parent
f662437b3f
commit
05e9230e9e
5 files changed
+12
-7
No files matched your search
@@ -126,7 +126,7 @@ class HostConnection extends BaseConnection {
|
||||
for (let instance of this._controller.instances.values()) {
|
||||
if (instance.config.get("instance.assigned_host") === this._id) {
|
||||
await libLink.messages.assignInstance.send(this, {
|
||||
instance_id: instance.config.get("instance.id"),
|
||||
instance_id: instance.id,
|
||||
serialized_config: instance.config.serialize("host"),
|
||||
});
|
||||
}
|
||||
@@ -142,7 +142,7 @@ class HostConnection extends BaseConnection {
|
||||
// Check if this instance is assigned somewhere else.
|
||||
if (controllerInstance.config.get("instance.assigned_host") !== this._id) {
|
||||
await libLink.messages.unassignInstance.send(this, {
|
||||
instance_id: controllerInstance.config.get("instance.id"),
|
||||
instance_id: controllerInstance.id,
|
||||
});
|
||||
continue;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user