nschum / homebridge-twinkly

36 stars 10 forks source link

Token error with recent version. #20

Closed budd33 closed 3 years ago

budd33 commented 3 years ago

[4/12/2021, 4:13:14 PM] ==================== [4/12/2021, 4:13:14 PM] ERROR LOADING PLUGIN homebridge-twinkly: [4/12/2021, 4:13:14 PM] /usr/lib/node_modules/homebridge-twinkly/index.js:125 let lastSeen = device.lastSeen?.toLocaleString() || "never"; ^

SyntaxError: Unexpected token '.' at Object.compileFunction (vm.js:344:18) at wrapSafe (internal/modules/cjs/loader.js:1048:15) at Module._compile (internal/modules/cjs/loader.js:1082:27) at Object.Module._extensions..js (internal/modules/cjs/loader.js:1138:10) at Module.load (internal/modules/cjs/loader.js:982:32) at Function.Module._load (internal/modules/cjs/loader.js:875:14) at Module.require (internal/modules/cjs/loader.js:1022:19) at require (internal/modules/cjs/helpers.js:72:18) at Plugin.load (/usr/lib/node_modules/homebridge/src/plugin.ts:187:27) at /usr/lib/node_modules/homebridge/src/pluginManager.ts:126:16 [4/12/2021, 4:13:14 PM] ====================

nschum commented 3 years ago

Looks like you need to update nodejs to 14.5, sorry.

budd33 commented 3 years ago

Updating the nodejs to v16.4.0 resolved the issue.