From d988d3a9959f5f41464d76897939b9f795b2e934 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lucas=20Ple=C3=9F?= Date: Wed, 23 Oct 2013 01:49:08 +0200 Subject: [PATCH] bugfix for node 0.10 https://github.com/joyent/libuv/issues/826 --- node/statusbot.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/node/statusbot.js b/node/statusbot.js index 70efa66..af33c52 100644 --- a/node/statusbot.js +++ b/node/statusbot.js @@ -1,4 +1,3 @@ -var _u = require("underscore"); var express = require('express'), app = express(), server = require('http').createServer(app), @@ -46,7 +45,7 @@ snmpMac.on('done', function (res) { ippoll.on('doneCount', function (num) { simpleanswer.count = num; simpleanswer.lastchange = new Date(); - io.sockets.emit('sdata', { data: simpleanswer }); + ippoll.pollState(); }); ippoll.on('doneState', function (state) { @@ -65,7 +64,6 @@ io.configure(function () { function work() { snmpMac.poll(); ippoll.pollCount(); - ippoll.pollState(); // simpleanswer.names.length = 0; // for(var i=0;i<4+Math.random() * 100;i++) {