Refactoring server.js, user-serttings popover