homebridge-melcloud-control 4.3.9-beta.6 → 4.3.9-beta.8

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "displayName": "MELCloud Control",
3
3
  "name": "homebridge-melcloud-control",
4
- "version": "4.3.9-beta.6",
4
+ "version": "4.3.9-beta.8",
5
5
  "description": "Homebridge plugin to control Mitsubishi Air Conditioner, Heat Pump and Energy Recovery Ventilation.",
6
6
  "license": "MIT",
7
7
  "author": "grzegorz914",
@@ -313,7 +313,7 @@ class MelCloudAta extends EventEmitter {
313
313
  //sens payload
314
314
  headers['Content-Type'] = 'application/json; charset=utf-8';
315
315
  headers.Origin = ApiUrlsHome.Origin;
316
- if (this.logDebug) this.emit('debug', `Send Data: ${JSON.stringify(payload, null, 2)}`);
316
+ if (!this.logDebug) this.emit('debug', `Send Data: ${JSON.stringify(payload, null, 2)}`);
317
317
 
318
318
  await axios(path, {
319
319
  method: method,
@@ -252,7 +252,7 @@ class MelCloudHome extends EventEmitter {
252
252
  })
253
253
  .on('message', (message) => {
254
254
  const parsedMessage = JSON.parse(message);
255
- if (this.logDebug) this.emit('debug', `Incoming message: ${JSON.stringify(parsedMessage, null, 2)}`);
255
+ if (!this.logDebug) this.emit('debug', `Incoming message: ${JSON.stringify(parsedMessage, null, 2)}`);
256
256
  if (parsedMessage.message === 'Forbidden') return;
257
257
 
258
258
  this.emit('webSocket', parsedMessage);