restructuring to work with node connect server on heroku