homebridge-xbox-tv 3.5.4 → 3.5.6

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/index.js CHANGED
@@ -133,7 +133,7 @@ class XboxPlatform {
133
133
  //start impulse generator
134
134
  await impulseGenerator.start([{ name: 'start', sampling: 45000 }]);
135
135
  } catch (error) {
136
- throw new Error(`Device: ${host} ${deviceName}, Did finish launching error: ${error}.`);
136
+ const emitLog = disableLogError ? false : log.error(`Device: ${host} ${deviceName}, Did finish launching error: ${error}.`);
137
137
  }
138
138
  await new Promise(resolve => setTimeout(resolve, 500));
139
139
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "displayName": "Xbox TV",
3
3
  "name": "homebridge-xbox-tv",
4
- "version": "3.5.4",
4
+ "version": "3.5.6",
5
5
  "description": "Homebridge plugin to control Xbox game consoles.",
6
6
  "license": "MIT",
7
7
  "author": "grzegorz914",
@@ -31,18 +31,18 @@
31
31
  "LICENSE"
32
32
  ],
33
33
  "engines": {
34
- "homebridge": "^1.9.0 || ^2.0.0 || ^2.0.0-beta.26 || ^2.0.0-alpha.37",
34
+ "homebridge": "^1.9.0 || ^2.0.0 || ^2.0.0-beta.27 || ^2.0.0-alpha.37",
35
35
  "node": "^18.20.4 || ^20.15.1 || ^22.7.0 || ^23.2.0"
36
36
  },
37
37
  "dependencies": {
38
- "@homebridge/plugin-ui-utils": "^2.0.1",
38
+ "@homebridge/plugin-ui-utils": "^2.0.2",
39
39
  "async-mqtt": "^2.6.3",
40
40
  "elliptic": "^6.6.1",
41
41
  "hex-to-binary": "^1.0.1",
42
42
  "jsrsasign": "^11.1.0",
43
43
  "uuid": "^11.1.0",
44
44
  "ping": "^0.4.4",
45
- "express": "^4.21.2",
45
+ "express": "^5.1.0",
46
46
  "axios": "^1.8.4"
47
47
  },
48
48
  "keywords": [
@@ -12,6 +12,10 @@ class ImpulseGenerator extends EventEmitter {
12
12
  return true;
13
13
  }
14
14
 
15
+ //update state
16
+ const updateState = timers.length > 0 ? this.state(true) : false;
17
+
18
+ //add timers
15
19
  this.timers = [];
16
20
  for (const timer of timers) {
17
21
  this.emit(timer.name);
@@ -22,8 +26,6 @@ class ImpulseGenerator extends EventEmitter {
22
26
  this.timers.push(newTimer);
23
27
  };
24
28
 
25
- //update state
26
- this.state(true);
27
29
  return true;
28
30
  }
29
31
 
@@ -36,6 +38,7 @@ class ImpulseGenerator extends EventEmitter {
36
38
  //update state
37
39
  this.timers.forEach(timer => clearInterval(timer));
38
40
  this.timers = [];
41
+
39
42
  this.state(false);
40
43
  return true
41
44
  }