Updated node file and added functionality of user.js added logged in functionality