homebridge-xbox-tv 2.12.0 → 2.12.1

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": "Xbox TV",
3
3
  "name": "homebridge-xbox-tv",
4
- "version": "2.12.0",
4
+ "version": "2.12.1",
5
5
  "description": "Homebridge plugin to control Xbox game consoles.",
6
6
  "license": "MIT",
7
7
  "author": "grzegorz914",
package/src/xboxdevice.js CHANGED
@@ -509,8 +509,8 @@ class XboxDevice extends EventEmitter {
509
509
  let payload;
510
510
  switch (this.power) {
511
511
  case false:
512
- await new Promise(resolve => setTimeout(resolve, 3000));
513
- this.televisionService.setCharacteristic(Characteristic.ActiveIdentifier, inputIdentifier);
512
+ await new Promise(resolve => setTimeout(resolve, 4000));
513
+ const tryAgain = this.power ? this.televisionService.setCharacteristic(Characteristic.ActiveIdentifier, inputIdentifier) : false;
514
514
  break;
515
515
  case true:
516
516
  switch (inputOneStoreProductId) {
@@ -840,7 +840,7 @@ class XboxDevice extends EventEmitter {
840
840
  return inputName;
841
841
  })
842
842
  .onSet(async (value) => {
843
- if (value === this.savedInputsNames[inputReference]) {
843
+ if (value === inputName) {
844
844
  return;
845
845
  }
846
846
 
@@ -859,7 +859,7 @@ class XboxDevice extends EventEmitter {
859
859
  return targetVisibility;
860
860
  })
861
861
  .onSet(async (state) => {
862
- if (state === this.savedInputsTargetVisibility[inputReference]) {
862
+ if (state === targetVisibility) {
863
863
  return;
864
864
  }
865
865