dehsgr / node-red-contrib-evohome

This provides nodes for controlling Honeywell Evohome
ISC License
5 stars 7 forks source link

Only map valid locations #14

Closed dimi-be closed 2 years ago

dimi-be commented 2 years ago

This is a fix for issue #1.

I found that in my case getLocations returns a location with no data for locationInfo trying to read the locationId property throws an exception that can't be handled in Node-RED.

I changed the code a bit to not map a locations without locationInfo. In that case getLocations returns an empty array, this in turn will trigger the creation of a new session in evohome-status.js.

dimi-be commented 2 years ago

I'm happy to help! It's just a small effort from my side.

Thank you for making these nodes!

On Wed, 2 Feb 2022, 16:51 dehsgr, @.***> wrote:

@.**** approved this pull request.

Thank you @dimi-be https://github.com/dimi-be for contributing and providing this fix. I'll publish a new version ASAP.

— Reply to this email directly, view it on GitHub https://github.com/dehsgr/node-red-contrib-evohome/pull/14#pullrequestreview-870745328, or unsubscribe https://github.com/notifications/unsubscribe-auth/AC2K2D4TJJ77I5SR2PE474TUZFHGTANCNFSM5NMIN5LA . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you were mentioned.Message ID: @.***>