Skip to content

Commit

Permalink
more error handling
Browse files Browse the repository at this point in the history
  • Loading branch information
edsu committed Dec 30, 2015
1 parent 6002ad3 commit 25adbed
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions app.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@ function main() {
_.each(latest, function(t) {socket.emit('tweet', t);});
});

io.sockets.on('error', function(e) {
console.log("socket error: " + e);
});

var tweets = new twitter(getConfig());
tweets.stream('statuses/filter', {track: 'wikipedia'}, function(stream) {
stream.on('data', function(t) {
Expand Down

0 comments on commit 25adbed

Please sign in to comment.