Skip to content

Commit

Permalink
better error verification for underground node
Browse files Browse the repository at this point in the history
to close #203
  • Loading branch information
Dave Conway-Jones committed Nov 19, 2017
1 parent 001a265 commit 9e00ace
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion weatherunderground/package.json
@@ -1,6 +1,6 @@
{
"name" : "node-red-node-weather-underground",
"version" : "0.1.10",
"version" : "0.1.11",
"description" : "A Node-RED node that gets the weather report and forecast from The Weather Underground",
"dependencies" : {
"wundergroundnode":"0.11.*"
Expand Down
2 changes: 1 addition & 1 deletion weatherunderground/wunder.js
Expand Up @@ -63,7 +63,7 @@ module.exports = function(RED) {
}

var handleResponse = function(res) {
if (res.response.hasOwnProperty("error")) {
if (res && res.hasOwnProperty("response") && res.response.hasOwnProperty("error")) {
callback(res.response.error);
}
else {
Expand Down

0 comments on commit 9e00ace

Please sign in to comment.