MadeByLoosers / noise-box

Broadcasting noise across the internet since 1972 - NoiseBox allows anyone to play sound clips through another computer...
http://noisebox.co
3 stars 3 forks source link

Crash error on production in user.js controller #46

Closed jedrichards closed 11 years ago

jedrichards commented 11 years ago

Mike said it happens when he was switch between preview/broadcast mode.

/var/node/noise-box/app/app/controllers/user.js:148
        track.user = nb.getUser(socket.id).get("username");
                                           ^
TypeError: Cannot call method 'get' of undefined
    at Object.UserController.onUserClickedTrack (/var/node/noise-box/app/app/controllers/user.js:148:44)
    at Socket.UserController.init (/var/node/noise-box/app/app/controllers/user.js:76:32)
    at Socket.EventEmitter.emit [as $emit] (events.js:96:17)
    at SocketNamespace.handlePacket (/var/node/noise-box/app/node_modules/socket.io/lib/namespace.js:335:22)
    at Manager.onClientMessage (/var/node/noise-box/app/node_modules/socket.io/lib/manager.js:488:38)
    at XHRPolling.Transport.onMessage (/var/node/noise-box/app/node_modules/socket.io/lib/transport.js:387:20)
    at XHRPolling.HTTPTransport.onData (/var/node/noise-box/app/node_modules/socket.io/lib/transports/http.js:99:10)
    at IncomingMessage.HTTPTransport.handleRequest.req.on.buffer (/var/node/noise-box/app/node_modules/socket.io/lib/transports/http.js:69:12)
    at IncomingMessage.EventEmitter.emit (events.js:93:17)
    at IncomingMessage._emitEnd (http.js:366:10)
orangespaceman commented 11 years ago

Only happens when not connecting via websockets - we're going to kick them out...