Skip to content

Commit

Permalink
Added error handling.
Browse files Browse the repository at this point in the history
  • Loading branch information
Rishabh Rao committed Dec 8, 2012
1 parent 16bda57 commit a883b00
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion js/main.js
Expand Up @@ -18,7 +18,7 @@ jQuery(document).ready(function() {

self.getItems = function() {
jQuery.ajax({
url: "http://www.tastekid.com/ask/ws",
url: "http://www.tastekid.com/ask/wsa",
type: "GET",
dataType: "jsonp",
async: true,
Expand Down Expand Up @@ -58,6 +58,8 @@ jQuery(document).ready(function() {
});
self.items.push(item);
}
} else {
console.error("No data fetched from server.");
}
}
});
Expand Down

0 comments on commit a883b00

Please sign in to comment.