Damien Arrachequesne
e4d61b1be6
Properly require EventEmitter
...
One must use `require('events').EventEmitter` in node.js 0.10.x
2017-05-16 07:09:38 +02:00
John Chadwick
9ad1fd2771
Remove process.EventEmitter usage for Node 7.x
...
process.EventEmitter has been deprecated and removed from Node.
2017-05-07 07:50:00 +02:00
einaros
63043b3d5d
fixes leak #608
2011-10-31 22:47:25 +01:00
Guillermo Rauch
0224e4ac5f
Merge pull request #569 from 3rd-Eden/blacklist
...
Blacklist events
2011-10-11 08:13:55 -07:00
Arnout Kazemier
ecd20b0e1f
Added support for blacklisting events that are emitted from the client side.
...
Currently it's possible for a client do .emit('disconnect') and this will trigger
the disconnect event on the server.. Which can lead to major issues.
We should black list that by default. You can override or add more events by adding
them to the `blacklist` setting
2011-10-11 10:40:22 +02:00
Arnout Kazemier
b8f6dc7810
Inital stab at blacklisting client side events
2011-10-11 09:53:26 +02:00
Arnout Kazemier
b3740e9ab6
fixes #538
2011-10-10 21:52:16 +02:00
Guillermo Rauch
7ac9c2e888
Fixed style
2011-09-03 10:48:23 -07:00
Guillermo Rauch
984639ba67
Merge pull request #381 from 3rd-Eden/alias
...
Added alias for to to in and in to to
2011-07-30 20:27:30 -07:00
Arnout Kazemier
a821cce390
Fix for #407
2011-07-22 22:52:20 +02:00
Arnout Kazemier
53f0f4d66d
Added alias for to to in and in to to
2011-07-14 21:31:55 +02:00
Guillermo Rauch
8798cfbced
Merge pull request #340 from 3rd-Eden/291
...
It was emitting uknown room, so the messages where never send
2011-07-12 00:55:49 -07:00
Guillermo Rauch
d3eac92eaa
Leveraged $emit instead of emit internally.
2011-07-12 04:28:55 -03:00
Arnout Kazemier
d39d1401c4
Fixed broken test suite
2011-07-05 00:59:31 +02:00
Arnout Kazemier
a70347b15f
Fixed #285
2011-07-05 00:37:19 +02:00
Arnout Kazemier
1a2c8aa31f
It was emitting uknown room, so the messages where never send fixes #291
2011-07-05 00:17:02 +02:00
Vladimir Dronnikov
44919189ec
normalize SocketNamespace local eventing
2011-06-30 03:12:55 -07:00
Arnout Kazemier
06e29fef67
Use packet.reason or default to 'packet'
2011-06-29 21:58:13 +02:00
Arnout Kazemier
16518c0715
Added a small indicator + test suite so you can see how a user is disconnected
2011-06-29 21:45:14 +02:00
Arnout Kazemier
299e097fa7
Added storage for socket.handshake & updated test suite to check for it
2011-06-28 23:50:33 +02:00
Arnout Kazemier
8abe712294
Passes test suite
2011-06-28 21:41:46 +02:00
Guillermo Rauch
fb79657476
Added SocketNamespace#clients
2011-06-28 13:33:01 -03:00
Guillermo Rauch
cbc12ecdcf
Make sure to leave rooms upon disconnection of a namespace (fixes some bug).
2011-06-27 15:31:44 -03:00
Guillermo Rauch
9aa650e430
Removed the join callback, since it's not necessary (TCP based pub/sub guarantees
...
proper total ordering).
2011-06-27 15:30:47 -03:00
Guillermo Rauch
f06fefab14
Added handleDisconnect method to emit the disconnect event when the socket is
...
disconnected due to network reasons, making sure we don't emit it on non-connected
namespaces.
2011-06-27 15:30:02 -03:00
Guillermo Rauch
5b6efb784f
Simplified global message dispatching by leveraging subscriptions.
2011-06-27 15:28:24 -03:00
Guillermo Rauch
bd2ce6ecf3
Fixed propagation of packets through SocketNamespace.
2011-06-13 12:10:23 -03:00
Guillermo Rauch
e574ba4a5c
Fixed; added echo connect packet for all namespaces connections.
2011-06-12 07:53:46 -03:00
Guillermo Rauch
50a8d2d50a
Revert.
2011-06-11 22:56:55 -03:00
Guillermo Rauch
2066aef41a
Changed; minor thingies.
2011-06-11 18:22:29 -03:00
Guillermo Rauch
13e9727e5c
Remove connection event upon socket initialization, this is now handled by the Manager.
2011-06-10 12:06:55 -03:00
Guillermo Rauch
4427b3e64b
Added SocketNamespace#except flag setter.
...
Added; keep track of exceptions (list of session ids) as part of flags, that then
get reset.
Fixed JSON double encoding.
2011-05-25 00:21:51 -07:00
Guillermo Rauch
3f030bd3fb
Fixed SocketNamespace#in, editing the endpoint flag directly instead of creating
...
`room`.
2011-05-24 23:46:31 -07:00
Guillermo Rauch
6e76229eb9
Make sure to encode packets in SocketNamespace#packet.
2011-05-24 23:25:30 -07:00
Guillermo Rauch
61eb0a2fd4
Added manual ack data callback handling.
2011-05-24 21:00:48 -07:00
Guillermo Rauch
aa3b99a630
Added Socket#$emit as the original EventEmitter emit
2011-05-24 18:51:40 -07:00
Guillermo Rauch
8416e76114
Added SocketNamespace#store shortcut.
...
Added SocketNamespace#in
Added SocketNamespace#for
Implemented SocketNamespace#packet
Fixed SocketNamespace#emit
Fixed SocketNamespace#send
2011-05-21 20:56:31 -07:00
Guillermo Rauch
0bebd38042
Changed; renamed SocketNamespace#nsp to SocketNamespace#name.
...
Changed; make sure to only emit the connection event when a client is registered for
the default namespace.
Added `connect` packet handler.
2011-05-16 19:41:52 -07:00
Guillermo Rauch
910995a8f2
Fixed emission of non-socket.io events in SocketNamespace.
2011-05-08 22:42:31 -07:00
Guillermo Rauch
d739f560b8
Added SocketNamespace#log getter.
...
Added SocketNamespace#socket to retrieve/create Sockets.
Added packet handling.
2011-05-08 20:34:28 -07:00
Guillermo Rauch
c2d0774d46
Removed const (slow)
2011-05-06 15:12:51 -07:00
Guillermo Rauch
1514af064f
Socket.IO 0.7-pre
2011-05-05 08:49:40 -07:00