In my app.js I have
io.sockets.on("connection", connectSocket);
and then in a different file I have:
const connectSocket = (socket, bitlyAppURL) => {
socket.once(AUTHENTICATED_CONNECTION_REQUEST, params => {
connectAuthenticatedSocket(socket, params, bitlyAppURL);
});
socket.once("disconnect", disconnectSocket);
socket.emit(AUTHENTICATE_YOURSELF);
};
but I'm not sure how to pass this bitlyAppURL into the function in app.js.