working version of server.js