homebridge-cmd4 6.0.3 → 6.0.4

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/CHANGELOG.md CHANGED
@@ -1,3 +1,10 @@
1
+ # Homebridges-cmd4 - CMD4 Plugin for Homebridge - Supports ~All Accessory Types and now all Characteristics too!!
2
+ #### 6.0.4 (2021-12-31)
3
+
4
+ ##### Bug Fixes
5
+
6
+ * Constants were not getting passed down to linked types ([b7252bf9](https://github.com/ztalbot2000/homebridge-cmd4/commit/b7252bf934e26535047008f343f4d6b627dd6ddb))
7
+
1
8
  # Homebridges-cmd4 - CMD4 Plugin for Homebridge - Supports ~All Accessory Types and now all Characteristics too!!
2
9
  ### 6.0.3 (2021-11-11)
3
10
 
package/Cmd4Accessory.js CHANGED
@@ -239,7 +239,13 @@ class Cmd4Accessory
239
239
 
240
240
  // Add the global constants to the listOfConstants
241
241
  if ( this.parentInfo && this.parentInfo.globalConstants != null )
242
+ {
242
243
  this.processConstants( this.parentInfo.globalConstants );
244
+ // Since linked accessories get processed first, The parentInfo they
245
+ // get is actually "this" and we need for the linked accessory to
246
+ // process the constants first in order to see them. i.e. ${IP}
247
+ this.globalConstants = this.parentInfo.globalConstants;
248
+ }
243
249
 
244
250
  // Direct if polling should be set or false.
245
251
  // You cannot copy polling from the parent because you would be copying the array
@@ -1342,6 +1348,8 @@ class Cmd4Accessory
1342
1348
  valueToAdd.replace(/^'/, "")
1343
1349
  valueToAdd.replace(/'$/, "")
1344
1350
 
1351
+ // Do not check for duplicates. Linked accessories add the same
1352
+ // ${IP} for example
1345
1353
  this.listOfConstants[ keyToAdd ] = valueToAdd;
1346
1354
  }
1347
1355
  }
@@ -3,6 +3,7 @@
3
3
  ## Homebridge UI User. Do not click on any inline links. Homebridge UI does not supprt them. Bug#1098
4
4
 
5
5
  ## ChangeLog
6
+ * <a href="#Whats-new-in-6-0-4">**Whats new in 6.0.4**</a>
6
7
  * <a href="#Whats-new-in-6-0-3">**Whats new in 6.0.3**</a>
7
8
  * <a href="#Whats-new-in-6-0-2">**Whats new in 6.0.2**</a>
8
9
  * <a href="#Whats-new-in-6-0-1">**Whats new in 6.0.1**</a>
@@ -78,6 +79,14 @@
78
79
  * <a href="#Whats-new-in-2-1">**Whats new in 2.1**</a>
79
80
  * <a href="#Whats-new-in-2-0">**Whats new in 2.0**</a>
80
81
 
82
+ <a name="Whats-new-in-6-0-4">## Whats new in 6.0.4</a>
83
+ #### 6.0.4 (2021-12-31)
84
+
85
+ ##### Bug Fixes
86
+
87
+ * Constants were not getting passed down to linked types ([b7252bf9](https://github.com/ztalbot2000/homebridge-cmd4/commit/b7252bf934e26535047008f343f4d6b627dd6ddb))
88
+
89
+
81
90
  <a name="Whats-new-in-6-0-3">## Whats new in 6.0.3</a>
82
91
  ### 6.0.3 (2021-11-11)
83
92
 
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "homebridge-cmd4",
3
3
  "description": "Exec Plugin for Homebridge supporting all accessorys and characteristics",
4
- "version": "6.0.3",
4
+ "version": "6.0.4",
5
5
  "license": "MIT",
6
6
  "author": {
7
7
  "name": "John Talbot"
@@ -112,4 +112,4 @@
112
112
  "release:minor": "tools/generateChangeLog --type minor --cleanup",
113
113
  "release:major": "tools/generateChangeLog --type major --cleanup"
114
114
  }
115
- }
115
+ }