Functions I use with Node.js & Socket.io or Angular & Socket.io