     # and handles multiple connections by user
     handleConnection: ->
         @io.on 'connection', (socket) =>
+            @emit 'connection', socket
             socket.user = socket.handshake.session.user
             # if the client isn't authenticated, do not continue
             unless socket.user then return

# modules
socketIo = require 'socket.io'

class WebSockets
    # socket.io object
    io: null
    users: {}


# export
module.exports = new WebSockets
