It seems you need to pass an argument to ender.receive, otherwise ender.connect (which is called by ender.receive) searches for nil in the connected channels list, which isn't there, so it calls rawStart to connect to 'nil'. rawStart calls http.get with a string concatenated with the channel which is nil, and baam, "attempt to concatenate string and nil"
Then, line 179,
chans[channel] --# needs to be:
chans[channel][1]
Sending doesn't work serverside, if I try to send "hey" in a browser, it errors:
TypeError: Object #<Object> has no method 'forEach'
at /var/lib/openshift/53a07cf1500446c6e3000183/app-root/runtime/repo/app/views/EnderCC.js:32:12
at Layer.handle [as handle_request] (/var/lib/openshift/53a07cf1500446c6e3000183/app-root/runtime/repo/node_modules/express/lib/router/layer.js:76:5)
at next (/var/lib/openshift/53a07cf1500446c6e3000183/app-root/runtime/repo/node_modules/express/lib/router/route.js:100:13)
at Route.dispatch (/var/lib/openshift/53a07cf1500446c6e3000183/app-root/runtime/repo/node_modules/express/lib/router/route.js:81:3)
at Layer.handle [as handle_request] (/var/lib/openshift/53a07cf1500446c6e3000183/app-root/runtime/repo/node_modules/express/lib/router/layer.js:76:5)
at /var/lib/openshift/53a07cf1500446c6e3000183/app-root/runtime/repo/node_modules/express/lib/router/index.js:227:24
at Function.proto.process_params (/var/lib/openshift/53a07cf1500446c6e3000183/app-root/runtime/repo/node_modules/express/lib/router/index.js:305:12)
at /var/lib/openshift/53a07cf1500446c6e3000183/app-root/runtime/repo/node_modules/express/lib/router/index.js:221:12
at Function.match_layer (/var/lib/openshift/53a07cf1500446c6e3000183/app-root/runtime/repo/node_modules/express/lib/router/index.js:288:3)
at next (/var/lib/openshift/53a07cf1500446c6e3000183/app-root/runtime/repo/node_modules/express/lib/router/index.js:182:10)
I love the idea, and I'd love to see this in action
Edited by ardera, 31 August 2014 - 03:51 PM.