homebridge-melcloud-control 4.0.0-beta.87 → 4.0.0-beta.88

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.
@@ -107,6 +107,16 @@
107
107
  }
108
108
  pluginConfig[0].accounts ??= [];
109
109
 
110
+ // Deep clone to prevent shared arrays
111
+ if (Array.isArray(pluginConfig?.[0]?.accounts)) {
112
+ pluginConfig[0].accounts = pluginConfig[0].accounts.map(acc => ({
113
+ ...acc,
114
+ ataDevices: Array.isArray(acc.ataDevices) ? [...acc.ataDevices] : [],
115
+ devices: Array.isArray(acc.devices) ? [...acc.devices] : [],
116
+ buildings: Array.isArray(acc.buildings) ? [...acc.buildings] : [],
117
+ }));
118
+ }
119
+
110
120
  this.accountIndex = 0;
111
121
  const accountsCount = pluginConfig[0].accounts.length;
112
122
 
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "displayName": "MELCloud Control",
3
3
  "name": "homebridge-melcloud-control",
4
- "version": "4.0.0-beta.87",
4
+ "version": "4.0.0-beta.88",
5
5
  "description": "Homebridge plugin to control Mitsubishi Air Conditioner, Heat Pump and Energy Recovery Ventilation.",
6
6
  "license": "MIT",
7
7
  "author": "grzegorz914",