hjdhjd / homebridge-myq

:car: myQ Liftmaster and Chamberlain Plugin for Homebridge https://github.com/nfarina/homebridge
Other
570 stars 44 forks source link

setCookie.map is not a function #1057

Closed fresler closed 1 year ago

fresler commented 1 year ago

Describe The Problem: When Homebridge tries to launch the myQ plug-in, it gets a "setCookie.map is not a function" error.

To Reproduce: I installed the plug-in from the Homebridge GUI and restarted it. I also had to rename server.js to server.cjs in order for the config popup to load.

Logs: TypeError: setCookie.map is not a function at myQApi.trimSetCookie (file:///var/lib/homebridge/node_modules/homebridge-myq/node_modules/@hjdhjd/myq/src/myq-api.ts:689:22) at myQApi.oauthRedirect (file:///var/lib/homebridge/node_modules/homebridge-myq/node_modules/@hjdhjd/myq/src/myq-api.ts:204:25) at myQApi.getOAuthToken (file:///var/lib/homebridge/node_modules/homebridge-myq/node_modules/@hjdhjd/myq/src/myq-api.ts:244:27) at processTicksAndRejections (node:internal/process/task_queues:95:5) at myQApi.acquireAccessToken (file:///var/lib/homebridge/node_modules/homebridge-myq/node_modules/@hjdhjd/myq/src/myq-api.ts:365:19) at myQApi.refreshAccessToken (file:///var/lib/homebridge/node_modules/homebridge-myq/node_modules/@hjdhjd/myq/src/myq-api.ts:407:14) at myQApi.refreshDevices (file:///var/lib/homebridge/node_modules/homebridge-myq/node_modules/@hjdhjd/myq/src/myq-api.ts:449:10) at myQPlatform.updateAccessories (file:///var/lib/homebridge/node_modules/homebridge-myq/src/myq-platform.ts:293:10) at file:///var/lib/homebridge/node_modules/homebridge-myq/src/myq-platform.ts:335:14

Show the Homebridge logs here.
Remove any sensitive information.

Homebridge Configuration:

{ "bridge": { "name": "Homebridge 552B", "username": "0E:C3:9F:31:55:2B", "port": 51545, "pin": "213-74-648", "advertiser": "avahi" }, "accessories": [ { "name": "Garage On", "stateful": true, "dimmer": false, "reverse": false, "time": 1000, "random": false, "resettable": false, "brightness": 0, "disableLogging": false, "accessory": "DummySwitch" } ], "platforms": [ { "name": "Config", "port": 8581, "platform": "config" }, { "refreshToken": "refreshtoken", "platform": "Ring" }, { "devices": [ { "name": "Living Room TV", "ip": "10.0.0.35", "mac": "7C:0A:3F:A8:29:45", "inputs": [ { "type": "app" } ] } ], "platform": "SamsungTizen" }, { "name": "Wyze", "username": "email", "password": "pw", "refreshInterval": 10000, "platform": "WyzeConnectedHome" }, { "email": "emai", "password": "pw", "name": "myQ", "platform": "myQ" } ], "disabledPlugins": [] }



**Screenshots:**
<!-- If applicable, add screenshots to help explain your problem. -->

**Environment:**

* **Homebridge Version:** 1.60
* **Node Version:** 18.15.0
* **Homebridge-myQ Plugin Version**: 2.10.0
* **Apple Device and iOS / macOS / iPadOS / tvOS Version:**<!-- Type of Apple device you're using and associated OS version -->
* **Operating System and OS Version:** Raspbian GNU/Linux Bullseye (11)

<!-- Click the "Preview" tab before you submit to ensure the formatting is correct. -->
hjdhjd commented 1 year ago

v2.10.2 should address these. Thanks for the report.

fresler commented 1 year ago

That did the trick! Thanks for the quick fix!