diff options
author | makefu <github@syntax-fehler.de> | 2013-11-06 19:31:26 +0100 |
---|---|---|
committer | makefu <github@syntax-fehler.de> | 2013-11-06 19:31:26 +0100 |
commit | a413089b542f7504fdf0bab1ef9b1fa5e7b26c32 (patch) | |
tree | 487047034eda74517fd85f8c1a9441ad69f3697b /webchat/hello_web.js | |
parent | 4140374e82f761b8aff74391d0f6c7c98f8abcd6 (diff) | |
parent | cd7baeae99a1e3835a9af1f00bbbcd442cea27e2 (diff) |
Merge branch 'master' of github.com:krebscode/painload
Diffstat (limited to 'webchat/hello_web.js')
-rw-r--r-- | webchat/hello_web.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/webchat/hello_web.js b/webchat/hello_web.js index 6f658901..45f6fc56 100644 --- a/webchat/hello_web.js +++ b/webchat/hello_web.js @@ -49,8 +49,8 @@ var echo = sockjs.createServer(); echo.on('connection', function(conn) { var origin = '['+conn.remoteAddress+':'+conn.remotePort+']'; Clients.push(conn); - irc_client.say("#krebs", name + ' has joined'); Clients.broadcast({from: 'system', message: origin + ' has joined'}) + irc_client.say("#krebs", origin + ' has joined'); conn.write(JSON.stringify({from: 'system', message: 'hello'})) conn.on('data', function(data) { console.log('data:',data); @@ -73,8 +73,8 @@ echo.on('connection', function(conn) { }); conn.on('close', function() { Clients.splice(Clients.indexOf(conn)); - irc_client.say("#krebs", name + ' has quit'); Clients.broadcast({from: 'system', message: origin + ' has quit'}) + irc_client.say("#krebs", origin + ' has quit'); }); }); |