homebridge-melcloud-control 4.0.0-beta.480 → 4.0.0-beta.481

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.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/src/melcloud.js +2 -3
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.480",
4
+ "version": "4.0.0-beta.481",
5
5
  "description": "Homebridge plugin to control Mitsubishi Air Conditioner, Heat Pump and Energy Recovery Ventilation.",
6
6
  "license": "MIT",
7
7
  "author": "grzegorz914",
package/src/melcloud.js CHANGED
@@ -325,8 +325,7 @@ class MelCloud extends EventEmitter {
325
325
  const pages = await browser.pages();
326
326
  let page = pages[0];
327
327
  if (!page) {
328
- this.emit('warn', `Test 13`);
329
- if (this.logDebug) this.emit('debug', 'No initial page found, creating a new one.');
328
+ if (this.logWarn) this.emit('warn', 'No initial page found, creating a new one.');
330
329
  page = await browser.newPage();
331
330
  }
332
331
 
@@ -350,7 +349,7 @@ class MelCloud extends EventEmitter {
350
349
  try {
351
350
  loginBtn = await page.waitForFunction(() => {
352
351
  const btns = Array.from(document.querySelectorAll('button.btn--blue'));
353
- this.emit('warn', `Test 5`);
352
+ this.emit('warn', `Test 5 ${btns}`);
354
353
  return btns.find(b => ['Zaloguj', 'Sign In', 'Login'].includes(b.textContent.trim()));
355
354
  }, { timeout: 25000 }); // max 25s czekania
356
355
  } catch {