Skip to content

Commit 24fc81e

Browse files
committed
Minor changes
### UPDATED - Properly detects ADT Pulse Gateway systems with no WAN IP Address. ### FIXED - Checks for when no force arming is required (no do submit handlers available). v3.0.3
1 parent d9bb7e5 commit 24fc81e

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "homebridge-adt-pulse",
33
"displayName": "Homebridge ADT Pulse",
4-
"version": "3.0.2",
4+
"version": "3.0.3",
55
"description": "Homebridge security system platform for ADT Pulse",
66
"main": "./build/src/index.js",
77
"exports": "./build/src/index.js",

src/lib/api.ts

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -869,6 +869,7 @@ export class ADTPulse {
869869
// If the parsing function may be parsing data incorrectly.
870870
if (
871871
Object.keys(fetchedTableCells).length !== 11 // Compact SMA Protocol Gateway / Cellular Mode.
872+
&& Object.keys(fetchedTableCells).length !== 17 // ADT Pulse Gateway / Broadband Mode / No Router WAN IP Address.
872873
&& Object.keys(fetchedTableCells).length !== 18 // ADT Pulse Gateway / Broadband Mode.
873874
) {
874875
if (this.#internal.debug) {
@@ -3156,14 +3157,17 @@ export class ADTPulse {
31563157
await this.newInformationDispatcher('do-submit-handlers', parsedDoSubmitHandlers);
31573158

31583159
// If the parsing function may be parsing data incorrectly.
3159-
if (parsedDoSubmitHandlers.length !== 2) {
3160+
if (
3161+
parsedDoSubmitHandlers.length !== 0 // No force arming required.
3162+
&& parsedDoSubmitHandlers.length !== 2 // Force arming required.
3163+
) {
31603164
if (this.#internal.debug) {
31613165
debugLog(this.#internal.logger, 'api.ts / ADTPulse.armDisarmHandler()', 'warn', 'The parseDoSubmitHandlers() function may be parsing the do submit handlers incorrectly');
31623166
}
31633167

31643168
await this.newInformationDispatcher('debug-parser', {
31653169
parserName: 'parseDoSubmitHandlers()',
3166-
parserReason: 'length does not match 2',
3170+
parserReason: 'length does not match 0 or 2',
31673171
parserResponse: parsedDoSubmitHandlers,
31683172
rawData: response.data,
31693173
});

0 commit comments

Comments
 (0)