Permalink
Browse files

Removed error checking.

  • Loading branch information...
Justin
Justin committed Apr 19, 2012
1 parent 1c34060 commit 1f8ab416e8a112ee1489b42ccd12ebaa198d0464
Showing with 2 additions and 3 deletions.
  1. +2 −3 server.js
View
@@ -52,6 +52,8 @@ app.get('/:ticker/', function(req, res) {
});
function get_quote(p_socket) {
+ console.log(ticker);
+
http.get({
host: 'www.google.com',
port: 80,
@@ -69,7 +71,6 @@ function get_quote(p_socket) {
try {
var data_object = JSON.parse(data.substring(3));
} catch(e) {
- p_socket.emit('quote', '{error: "Confirm that the provided ticker \'' + ticker + '\' is correct."}');
return;
}
@@ -84,8 +85,6 @@ function get_quote(p_socket) {
quote.yield = data_object[0].yld;
p_socket.emit('quote', PRETTY_PRINT_JSON ? JSON.stringify(quote, true, '\t') : JSON.stringify(quote));
- } else {
- p_socket.emit('quote', '{error: "Confirm that the provided ticker \'' + ticker + '\' is correct."}');
}
});
});

0 comments on commit 1f8ab41

Please sign in to comment.