Renamed translation file, so it matches MagicMirror2 language codes
Fixed some inconsistent use of whitespace in node_helper.js
Display an error message if the locationId does not support NowCast, by emitting a YR_INVALID_NOWCAST socket notification from the node helper.
The bigger change is that I've added support for multiple instances:
It now also queries the base url for a location, e.g https://www.yr.no/api/v0/locations/1-123456/ to get the place name. This is done once only for each module instance
For all socket notifications, the forecastUrl is passed along. node_helper.js stores each instance's passed configuration in an array using the URL as key. Each module instance further only listens to its own forecastUrl when the helper emits them.
This request contains a number of small fixes:
node_helper.js
locationId
does not support NowCast, by emitting aYR_INVALID_NOWCAST
socket notification from the node helper.The bigger change is that I've added support for multiple instances:
https://www.yr.no/api/v0/locations/1-123456/
to get the place name. This is done once only for each module instanceforecastUrl
is passed along.node_helper.js
stores each instance's passed configuration in an array using the URL as key. Each module instance further only listens to its own forecastUrl when the helper emits them.I hope this change is a useful one for you.